Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
52 changes: 48 additions & 4 deletions .github/workflows/ci-test-integration.yml
Original file line number Diff line number Diff line change
Expand Up @@ -11,12 +11,13 @@ on:
types: [opened, reopened, synchronize, ready_for_review]

jobs:
run_make_ci_test:
if: github.event.pull_request.draft == false
build:
if: github.event_name != 'pull_request' || !github.event.pull_request.draft
runs-on: extra-large
name: Build Project
steps:
- name: Checkout this magicblock-validator
uses: actions/checkout@v2
uses: actions/checkout@v5
with:
path: magicblock-validator

Expand All @@ -29,11 +30,54 @@ jobs:

- uses: ./magicblock-validator/.github/actions/setup-solana

- name: Run integration tests
- name: Build project and test programs
run: |
cargo build --locked
make -C test-integration programs
shell: bash
working-directory: magicblock-validator

run_integration_tests:
needs: build
runs-on: extra-large
strategy:
matrix:
batch_tests:
- "schedulecommit"
- "chainlink"
- "cloning"
- "restore_ledger"
- "magicblock_api"
- "config"
- "table_mania"
- "committor"
- "pubsub"
- "schedule_intents"
- "task-scheduler"
fail-fast: false
name: Integration Tests - ${{ matrix.batch_tests }}
steps:
- name: Checkout this magicblock-validator
uses: actions/checkout@v5
with:
path: magicblock-validator

- uses: ./magicblock-validator/.github/actions/setup-build-env
with:
build_cache_key_name: "magicblock-validator-ci-test-integration-v000"
rust_toolchain_release: "1.84.1"
github_access_token: ${{ secrets.GH_PERSONAL_ACCESS_TOKEN }}
github_token: ${{ secrets.GITHUB_TOKEN }}

- uses: ./magicblock-validator/.github/actions/setup-solana

- name: Run integration tests - ${{ matrix.batch_tests }}
run: |
sudo prlimit --pid $$ --nofile=1048576:1048576
sudo sysctl fs.inotify.max_user_instances=1280
sudo sysctl fs.inotify.max_user_watches=655360
make ci-test-integration
shell: bash
working-directory: magicblock-validator
env:
RUN_TESTS: ${{ matrix.batch_tests }}
3 changes: 1 addition & 2 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -52,8 +52,7 @@ ci-test-unit:
RUST_BACKTRACE=1 cargo $(CARGO_TEST_NOCAP)

ci-test-integration:
cargo build --locked && \
$(MAKE) -C $(DIR)/test-integration test
RUN_TESTS=$(RUN_TESTS) $(MAKE) -C $(DIR)/test-integration test

## NOTE: We're getting the following error in github CI when trying to use
# nightly Rust. Until that is fixed we have to use stable to verify format.
Expand Down