From ab60f09767aa4d450ec4e31e74fab69922e71d02 Mon Sep 17 00:00:00 2001 From: 4ever2 <3417013+4ever2@users.noreply.github.com> Date: Wed, 26 Jun 2024 15:54:39 +0200 Subject: [PATCH] Split tests into separate job --- .github/workflows/build.yml | 88 +++++++++++++++++++++---------------- 1 file changed, 50 insertions(+), 38 deletions(-) diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index ccccf30d..36862917 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -87,6 +87,56 @@ jobs: opam exec -- make -j${{ env.JOBS }} examples echo "::endgroup::" + - name: Upload extraction results + uses: actions/upload-artifact@v4 + with: + name: extraction-results + path: extraction/tests/extracted-code + retention-days: 2 + + - name: Build documentation + if: github.event_name == 'push' && github.ref == 'refs/heads/master' + run: | + echo "::group::Running coqdoc" + opam exec -- make -j${{ env.JOBS }} html + echo "::endgroup::" + + echo "::group::Install dependencies" + sudo apt install -y graphviz + echo "::endgroup::" + + echo "::group::Generate dependency graphs" + rm -rf docs/graphs + mkdir -p docs + mkdir -p docs/graphs + + opam exec -- make dependency-graphs + mv utils/svg/* docs/graphs/ + mv execution/svg/* docs/graphs/ + mv embedding/svg/* docs/graphs/ + mv extraction/svg/* docs/graphs/ + mv examples/svg/* docs/graphs/ + echo "::endgroup::" + + - name: Prepare documentation for deployment + if: github.event_name == 'push' && github.ref == 'refs/heads/master' + uses: actions/upload-pages-artifact@v3 + with: + path: docs + + test: + needs: build + runs-on: ubuntu-latest + steps: + - name: Checkout branch ${{ github.ref_name }} + uses: actions/checkout@v4 + + - name: Download extraction results + uses: actions/download-artifact@v4 + with: + name: extraction-results + path: extraction/tests/extracted-code + - name: Set up Rust uses: actions-rs/toolchain@v1 with: @@ -116,14 +166,6 @@ jobs: make -j${{ env.JOBS }} test-extraction echo "::endgroup::" - - name: Upload Liquidity extraction logs - if: false # Do we still want these logs? - uses: actions/upload-artifact@v4 - with: - name: Liquidity logs - path: extraction/tests/extracted-code/liquidity-extract/liquidity.log - retention-days: 14 - - name: Prepare extraction results if: github.event_name == 'push' && github.repository == 'AU-COBRA/ConCert' && github.ref == 'refs/heads/master' run: | @@ -151,36 +193,6 @@ jobs: commit-message: See ORIGIN_COMMIT from $GITHUB_REF target-branch: master - - name: Build documentation - if: github.event_name == 'push' && github.ref == 'refs/heads/master' - run: | - echo "::group::Running coqdoc" - opam exec -- make -j${{ env.JOBS }} html - echo "::endgroup::" - - echo "::group::Install dependencies" - sudo apt install -y graphviz - echo "::endgroup::" - - echo "::group::Generate dependency graphs" - rm -rf docs/graphs - mkdir -p docs - mkdir -p docs/graphs - - opam exec -- make dependency-graphs - mv utils/svg/* docs/graphs/ - mv execution/svg/* docs/graphs/ - mv embedding/svg/* docs/graphs/ - mv extraction/svg/* docs/graphs/ - mv examples/svg/* docs/graphs/ - echo "::endgroup::" - - - name: Prepare documentation for deployment - if: github.event_name == 'push' && github.ref == 'refs/heads/master' - uses: actions/upload-pages-artifact@v3 - with: - path: docs - deploy-docs: if: github.event_name == 'push' && github.ref == 'refs/heads/master' needs: build