derive target epoch from proposal in proposal prelim validated handler #6053
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: HotShot integration tests | |
| on: | |
| push: | |
| branches: | |
| - "main" | |
| pull_request: | |
| schedule: | |
| - cron: "0 0 * * 1" | |
| workflow_dispatch: | |
| concurrency: | |
| # ensure non-PR jobs run in parallel | |
| group: ${{ github.workflow }}-${{ github.head_ref || github.run_id }} | |
| cancel-in-progress: ${{ github.event_name == 'pull_request' }} | |
| env: | |
| CARGO_INCREMENTAL: "0" | |
| jobs: | |
| build-matrix: | |
| runs-on: ubuntu-latest | |
| outputs: | |
| matrix: ${{ steps.set-matrix.outputs.matrix }} | |
| steps: | |
| - uses: actions/checkout@v4 | |
| - uses: taiki-e/install-action@just | |
| - id: set-matrix | |
| run: echo "matrix=$(just hotshot::matrix)" >> "$GITHUB_OUTPUT" | |
| test: | |
| needs: build-matrix | |
| strategy: | |
| matrix: ${{ fromJson(needs.build-matrix.outputs.matrix) }} | |
| fail-fast: false | |
| runs-on: ubuntu-latest | |
| steps: | |
| - uses: actions/checkout@v4 | |
| name: Checkout Repository | |
| - uses: Swatinem/rust-cache@v2 | |
| name: Enable Rust Caching | |
| with: | |
| shared-key: "hotshot-tests" | |
| cache-on-failure: "true" | |
| save-if: ${{ github.ref == 'refs/heads/main' && matrix.test_suites == 'test-ci-rest' }} | |
| prefix-key: v1-hotshot | |
| - uses: taiki-e/install-action@just | |
| - uses: taiki-e/install-action@nextest | |
| - name: Show memory | |
| run: free -h | |
| - name: Collect Workflow Telemetry | |
| uses: catchpoint/workflow-telemetry-action@v2 | |
| with: | |
| comment_on_pr: false | |
| - name: Build integration tests | |
| run: | | |
| just hotshot::${{ matrix.test_suites }} --no-run | |
| timeout-minutes: 60 | |
| - name: Run integration tests | |
| run: | | |
| just hotshot::${{ matrix.test_suites }} --no-fail-fast | |
| timeout-minutes: 60 | |
| env: | |
| RUST_BACKTRACE: full | |
| test-examples: | |
| strategy: | |
| fail-fast: false | |
| runs-on: ubuntu-latest | |
| steps: | |
| - uses: actions/checkout@v4 | |
| name: Checkout Repository | |
| - uses: Swatinem/rust-cache@v2 | |
| name: Enable Rust Caching | |
| with: | |
| shared-key: "hotshot-examples" | |
| cache-on-failure: "true" | |
| save-if: ${{ github.ref == 'refs/heads/main' }} | |
| prefix-key: v0-hotshot | |
| - uses: taiki-e/install-action@just | |
| - name: Test examples | |
| run: | | |
| just hotshot::example all-push-cdn -- --config_file ./crates/hotshot/orchestrator/run-config.toml | |
| timeout-minutes: 20 | |
| # This job enables having a single required status check in github for all hotshot tests. | |
| aggregate-hotshot-tests: | |
| needs: [test, test-examples] | |
| runs-on: ubuntu-latest | |
| # explicitly run and fail the job if dependencies failed | |
| if: ${{ always() && !cancelled() }} | |
| steps: | |
| - name: Aggregate hotshot test results | |
| run: | | |
| # useful for debugging | |
| echo "All results: ${{ toJson(needs) }}" | |
| if ${{ contains(needs.*.result, 'failure') || contains(needs.*.result, 'cancelled') }}; then | |
| echo "One or more jobs failed." | |
| exit 1 | |
| else | |
| echo "All jobs succeeded." | |
| exit 0 | |
| fi |