Papyrus-Nightly-Tests #144
This file contains 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: Papyrus-Nightly-Tests | |
# We run gateway_integration_test at different times, to avoid a nonce race between parallel runs. | |
on: | |
schedule: | |
- cron: '30 22 * * *' # Uses ubuntu runner. | |
- cron: '30 0 * * *' # Uses macos runner. | |
workflow_dispatch: # Uses ubuntu runner. | |
env: | |
PROTOC_VERSION: 25 # homebrew doesn't support minor versions | |
jobs: | |
GW-integration-test-ubuntu: | |
uses: ./.github/workflows/papyrus_nightly-tests-call.yml | |
with: | |
os: starkware-ubuntu-latest-small | |
secrets: | |
INTEGRATION_TESTNET_NODE_URL: ${{ secrets.INTEGRATION_TESTNET_NODE_URL }} | |
INTEGRATION_TESTNET_SENDER_PRIVATE_KEY: ${{ secrets.INTEGRATION_TESTNET_SENDER_PRIVATE_KEY }} | |
SLACK_ALERT_CHANNEL: ${{ secrets.SLACK_ALERT_CHANNEL }} | |
SLACK_BOT_TOKEN: ${{ secrets.SLACK_BOT_TOKEN }} | |
if: github.event.schedule != '30 0 * * *' | |
GW-integration-test-macos: | |
uses: ./.github/workflows/papyrus_nightly-tests-call.yml | |
with: | |
os: macos-latest | |
secrets: | |
INTEGRATION_TESTNET_NODE_URL: ${{ secrets.INTEGRATION_TESTNET_NODE_URL }} | |
INTEGRATION_TESTNET_SENDER_PRIVATE_KEY: ${{ secrets.INTEGRATION_TESTNET_SENDER_PRIVATE_KEY }} | |
SLACK_ALERT_CHANNEL: ${{ secrets.SLACK_ALERT_CHANNEL }} | |
SLACK_BOT_TOKEN: ${{ secrets.SLACK_BOT_TOKEN }} | |
if: github.event.schedule == '30 0 * * *' | |
executable-run: | |
runs-on: macos-latest | |
if: github.event.schedule == '30 0 * * *' | |
steps: | |
- uses: actions/checkout@v4 | |
- uses: ./.github/actions/install_rust | |
- uses: Swatinem/rust-cache@v2 | |
- run: mkdir data | |
- run: brew install protobuf@$PROTOC_VERSION | |
- name: Build node | |
run: cargo build -r -p papyrus_node | |
- name: Run executable | |
run: > | |
target/release/papyrus_node --base_layer.node_url ${{ secrets.CI_BASE_LAYER_NODE_URL }} | |
& sleep 30 ; kill $! | |
test: | |
runs-on: macos-latest | |
if: github.event.schedule == '30 0 * * *' | |
steps: | |
- uses: actions/checkout@v4 | |
- uses: ./.github/actions/install_rust | |
- uses: Swatinem/rust-cache@v2 | |
- run: npm install -g ganache@7.4.3 | |
- run: brew install protobuf@$PROTOC_VERSION | |
- run: | | |
cargo test -r -p papyrus_node | |
env: | |
SEED: 0 | |
build-load-test: | |
runs-on: macos-latest | |
if: github.event.schedule == '30 0 * * *' | |
steps: | |
- uses: actions/checkout@v4 | |
- uses: ./.github/actions/install_rust | |
- uses: Swatinem/rust-cache@v2 | |
- run: cargo build -r -p papyrus_load_test | |
integration-test: | |
runs-on: macos-latest | |
if: github.event.schedule == '30 0 * * *' | |
steps: | |
- uses: actions/checkout@v4 | |
- uses: ./.github/actions/install_rust | |
- uses: Swatinem/rust-cache@v2 | |
- run: > | |
cargo test -r | |
--test latency_histogram | |
--test gateway_integration_test | |
--test feeder_gateway_integration_test | |
-- --include-ignored --skip test_gw_integration_testnet; | |
cargo run -r -p papyrus_node --bin central_source_integration_test --features="futures-util tokio-stream" | |
# TODO(dvir): make this run only if the path 'crates/papyrus_storage/src/db/**' (same path as in the CI) was changed on the | |
# last day and increase the number of repetitions. | |
random-table-test: | |
runs-on: starkware-ubuntu-latest-small | |
steps: | |
- uses: actions/checkout@v4 | |
- uses: ./.github/actions/install_rust | |
- uses: Swatinem/rust-cache@v2 | |
- run: for run in {1..100}; do cargo test -r -p papyrus_storage -- --include-ignored common_prefix_compare_with_simple_table_random; done |