Skip to content

Commit

Permalink
Split tests into separate job
Browse files Browse the repository at this point in the history
  • Loading branch information
4ever2 committed Jun 26, 2024
1 parent c47801f commit ab60f09
Showing 1 changed file with 50 additions and 38 deletions.
88 changes: 50 additions & 38 deletions .github/workflows/build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -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:
Expand Down Expand Up @@ -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: |
Expand Down Expand Up @@ -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
Expand Down

0 comments on commit ab60f09

Please sign in to comment.