-
Notifications
You must be signed in to change notification settings - Fork 1
Add downstream-check CI (builds Strata-Boogie against CLI PRs) #6
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Draft
shigoel
wants to merge
2
commits into
main
Choose a base branch
from
add-downstream-check
base: main
Could not load branches
Branch not found: {{ refName }}
Loading
Could not load tags
Nothing to show
Loading
Are you sure you want to change the base?
Some commits from the old base branch may be removed from the timeline,
and old review comments may become outdated.
Draft
Changes from all commits
Commits
Show all changes
2 commits
Select commit
Hold shift + click to select a range
File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,92 @@ | ||
| # Copyright Strata Contributors | ||
| # SPDX-License-Identifier: Apache-2.0 OR MIT | ||
| # | ||
| # Downstream check: builds Strata-Boogie against this PR's Strata-CLI code, so | ||
| # we catch breakage before it lands on main. Advisory only — visible on the PR | ||
| # but does not gate merge. | ||
| # | ||
| # Strata-Boogie is a .NET project, not a Lake package: it does not `require` | ||
| # Strata-CLI in a lakefile. Instead it builds the `strata` binary from | ||
| # Strata-CLI and runs `dotnet test` against it via STRATA_VERIFIER_PATH. So | ||
| # this check mirrors Strata-Boogie's own CI, but builds `strata` from the PR's | ||
| # checked-out Strata-CLI rather than a fresh clone of CLI's main. | ||
| # | ||
| # Trigger: non-draft PRs only (ready_for_review + every push via synchronize). | ||
|
|
||
| name: Downstream check | ||
|
|
||
| on: | ||
| pull_request: | ||
| types: [ready_for_review, synchronize] | ||
|
|
||
| concurrency: | ||
| group: downstream-${{ github.event.pull_request.number }} | ||
| cancel-in-progress: true | ||
|
|
||
| permissions: | ||
| contents: read | ||
|
|
||
| jobs: | ||
| downstream: | ||
| if: ${{ !github.event.pull_request.draft }} | ||
| runs-on: ubuntu-latest | ||
| name: Strata-Boogie | ||
| steps: | ||
| - name: Check out PR's Strata-CLI | ||
| uses: actions/checkout@v6 | ||
| with: | ||
| ref: ${{ github.event.pull_request.head.sha }} | ||
| path: StrataCLI | ||
|
|
||
| - name: Clone Strata-Boogie | ||
| run: git clone --depth 1 https://github.com/strata-org/Strata-Boogie.git downstream | ||
|
|
||
| - name: Install cvc5 | ||
| uses: ./StrataCLI/.github/actions/install-cvc5 | ||
| - name: Setup .NET | ||
| uses: actions/setup-dotnet@v5 | ||
| with: | ||
| dotnet-version: '8.0.x' | ||
|
|
||
| - name: Restore lake cache | ||
| uses: actions/cache/restore@v5 | ||
| with: | ||
| path: | | ||
| StrataCLI/.lake | ||
| key: downstream-Boogie-${{ runner.os }}-${{ github.event.pull_request.head.sha }} | ||
| restore-keys: | | ||
| downstream-Boogie-${{ runner.os }}- | ||
|
|
||
| # Build the `strata` binary from the PR's Strata-CLI — this is the | ||
| # artifact Strata-Boogie's integration tests verify against. | ||
| - name: Build strata binary from PR's Strata-CLI | ||
| uses: leanprover/lean-action@v1 | ||
| with: | ||
| build-args: strata | ||
| test: false | ||
| lake-package-directory: StrataCLI | ||
| use-github-cache: false | ||
|
|
||
| - name: Save lake cache | ||
| if: always() | ||
| uses: actions/cache/save@v5 | ||
| with: | ||
| path: | | ||
| StrataCLI/.lake | ||
| key: downstream-Boogie-${{ runner.os }}-${{ github.event.pull_request.head.sha }} | ||
|
|
||
| - name: Restore .NET dependencies | ||
| working-directory: downstream | ||
| run: dotnet restore BoogieToStrata.sln | ||
|
|
||
| - name: Build Strata-Boogie | ||
| working-directory: downstream | ||
| run: dotnet build BoogieToStrata.sln --no-restore | ||
|
|
||
| - name: Run Strata-Boogie integration tests | ||
| working-directory: downstream | ||
| env: | ||
| # Point Boogie's tests at the strata binary built above. The CLI | ||
| # checkout lives at <workspace>/StrataCLI, sibling to downstream/. | ||
| STRATA_VERIFIER_PATH: ${{ github.workspace }}/StrataCLI/.lake/build/bin/strata | ||
| run: dotnet test IntegrationTests/BoogieToStrata.IntegrationTests.csproj --no-build --verbosity normal | ||
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Uh oh!
There was an error while loading. Please reload this page.