ci: make conformance checks non-blocking #650
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
| name: CI | |
| on: | |
| workflow_dispatch: | |
| pull_request: | |
| push: | |
| branches: [main] | |
| permissions: | |
| contents: read | |
| concurrency: | |
| group: ci-${{ github.ref }} | |
| cancel-in-progress: true | |
| env: | |
| CARGO_TERM_COLOR: always | |
| jobs: | |
| fmt: | |
| runs-on: ubuntu-latest | |
| steps: | |
| - uses: actions/checkout@v6.0.2 | |
| - uses: dtolnay/rust-toolchain@stable | |
| - run: cargo fmt --all --check | |
| detect-secrets: | |
| runs-on: ubuntu-latest | |
| timeout-minutes: 10 | |
| steps: | |
| - uses: actions/checkout@v6.0.2 | |
| - name: Run detect-secrets | |
| run: scripts/ci/detect-secrets.sh | |
| clippy: | |
| runs-on: ubuntu-latest | |
| steps: | |
| - uses: actions/checkout@v6.0.2 | |
| - uses: dtolnay/rust-toolchain@stable | |
| with: | |
| components: clippy | |
| - uses: Swatinem/rust-cache@v2.9.1 | |
| - run: cargo clippy --locked --workspace --all-targets -- -D warnings | |
| cargo-deny: | |
| runs-on: ubuntu-latest | |
| steps: | |
| - uses: actions/checkout@v6.0.2 | |
| - uses: dtolnay/rust-toolchain@stable | |
| - uses: taiki-e/install-action@v2.75.27 | |
| with: | |
| tool: cargo-deny | |
| - run: cargo deny check advisories bans licenses | |
| cargo-shear: | |
| runs-on: ubuntu-latest | |
| steps: | |
| - uses: actions/checkout@v6.0.2 | |
| - uses: dtolnay/rust-toolchain@stable | |
| - uses: Swatinem/rust-cache@v2.9.1 | |
| - run: cargo install cargo-shear --version 1.12.4 --locked | |
| - run: cargo shear --check-test-targets --deny-warnings --locked | |
| test: | |
| runs-on: ubuntu-latest | |
| steps: | |
| - uses: actions/checkout@v6.0.2 | |
| - uses: dtolnay/rust-toolchain@stable | |
| - uses: Swatinem/rust-cache@v2.9.1 | |
| - uses: taiki-e/install-action@v2.75.27 | |
| with: | |
| tool: cargo-nextest | |
| - run: cargo nextest run --locked --workspace --all-features | |
| build: | |
| runs-on: ubuntu-latest | |
| steps: | |
| - uses: actions/checkout@v6.0.2 | |
| - uses: dtolnay/rust-toolchain@stable | |
| - uses: Swatinem/rust-cache@v2.9.1 | |
| - name: Build the workspace | |
| run: cargo build --locked --workspace --all-features | |
| - name: Prepare the conformance binary artifact | |
| run: | | |
| mkdir -p target/conformance | |
| cp target/debug/contextforge-data-plane target/conformance/contextforge-data-plane | |
| strip target/conformance/contextforge-data-plane | |
| - name: Upload the conformance binary | |
| uses: actions/upload-artifact@v7.0.1 | |
| with: | |
| name: contextforge-data-plane-conformance | |
| path: target/conformance/contextforge-data-plane | |
| if-no-files-found: error | |
| retention-days: 1 | |
| bench: | |
| runs-on: ubuntu-latest | |
| steps: | |
| - uses: actions/checkout@v6.0.2 | |
| - uses: dtolnay/rust-toolchain@stable | |
| - uses: Swatinem/rust-cache@v2.9.1 | |
| - run: cargo bench --locked --workspace --no-run | |
| conformance: | |
| needs: build | |
| uses: ./.github/workflows/mcp_conformance.yml |