|
23 | 23 |
|
24 | 24 | - uses: ./magicblock-validator/.github/actions/setup-build-env |
25 | 25 | with: |
26 | | - build_cache_key_name: "magicblock-validator-ci-test-integration-${{ github.ref_name }}-${{ hashFiles('magicblock-validator/Cargo.lock') }}" |
| 26 | + build_cache_key_name: "magicblock-validator-${{ hashFiles('magicblock-validator/Cargo.lock', 'magicblock-validator/test-integration/Cargo.lock') }}-v001" |
27 | 27 | rust_toolchain_release: "1.91.1" |
28 | 28 | github_access_token: ${{ secrets.GH_PERSONAL_ACCESS_TOKEN }} |
29 | 29 | github_token: ${{ secrets.GITHUB_TOKEN }} |
|
37 | 37 | shell: bash |
38 | 38 | working-directory: magicblock-validator |
39 | 39 |
|
| 40 | + - name: Build test-runner binary |
| 41 | + run: cargo build --package test-runner --bin run-tests --locked |
| 42 | + shell: bash |
| 43 | + working-directory: magicblock-validator |
| 44 | + |
| 45 | + - name: Pre-build all test binaries |
| 46 | + run: cargo build --tests --locked |
| 47 | + shell: bash |
| 48 | + working-directory: magicblock-validator/test-integration |
| 49 | + |
| 50 | + - name: Upload test-runner binary |
| 51 | + uses: actions/upload-artifact@v3 |
| 52 | + with: |
| 53 | + name: test-runner-binary |
| 54 | + path: magicblock-validator/test-integration/target/debug/run-tests |
| 55 | + retention-days: 1 |
| 56 | + |
40 | 57 | run_integration_tests: |
41 | 58 | needs: build |
42 | 59 | runs-on: ubuntu-latest-m |
@@ -64,13 +81,23 @@ jobs: |
64 | 81 |
|
65 | 82 | - uses: ./magicblock-validator/.github/actions/setup-build-env |
66 | 83 | with: |
67 | | - build_cache_key_name: "magicblock-validator-ci-test-integration-${{ github.ref_name }}-${{ hashFiles('magicblock-validator/Cargo.lock') }}" |
68 | | - rust_toolchain_release: "1.84.1" |
| 84 | + build_cache_key_name: "magicblock-validator-${{ hashFiles('magicblock-validator/Cargo.lock', 'magicblock-validator/test-integration/Cargo.lock') }}-v001" |
| 85 | + rust_toolchain_release: "1.91.1" |
69 | 86 | github_access_token: ${{ secrets.GH_PERSONAL_ACCESS_TOKEN }} |
70 | 87 | github_token: ${{ secrets.GITHUB_TOKEN }} |
71 | 88 |
|
72 | 89 | - uses: ./magicblock-validator/.github/actions/setup-solana |
73 | 90 |
|
| 91 | + - name: Download test-runner binary |
| 92 | + uses: actions/download-artifact@v3 |
| 93 | + with: |
| 94 | + name: test-runner-binary |
| 95 | + path: magicblock-validator/test-integration/target/debug/ |
| 96 | + |
| 97 | + - name: Make test-runner binary executable |
| 98 | + run: chmod +x magicblock-validator/test-integration/target/debug/run-tests |
| 99 | + shell: bash |
| 100 | + |
74 | 101 | - name: Run integration tests - ${{ matrix.batch_tests }} |
75 | 102 | run: | |
76 | 103 | sudo prlimit --pid $$ --nofile=1048576:1048576 |
|
81 | 108 | working-directory: magicblock-validator |
82 | 109 | env: |
83 | 110 | RUN_TESTS: ${{ matrix.batch_tests }} |
| 111 | + TEST_RUNNER_BIN: ${{ github.workspace }}/magicblock-validator/test-integration/target/debug/run-tests |
0 commit comments