mirror of
https://github.com/logos-blockchain/logos-execution-zone.git
synced 2026-03-28 13:13:08 +00:00
test: ci test 2.0
This commit is contained in:
parent
fb083ce91e
commit
15f026f061
292
.github/workflows/ci.yml
vendored
292
.github/workflows/ci.yml
vendored
@ -14,147 +14,147 @@ on:
|
|||||||
name: General
|
name: General
|
||||||
|
|
||||||
jobs:
|
jobs:
|
||||||
fmt-rs:
|
# fmt-rs:
|
||||||
runs-on: ubuntu-latest
|
# runs-on: ubuntu-latest
|
||||||
steps:
|
# steps:
|
||||||
- uses: actions/checkout@v5
|
# - uses: actions/checkout@v5
|
||||||
with:
|
# with:
|
||||||
ref: ${{ github.head_ref }}
|
# ref: ${{ github.head_ref }}
|
||||||
|
|
||||||
- name: Install nightly toolchain for rustfmt
|
# - name: Install nightly toolchain for rustfmt
|
||||||
run: rustup install nightly --profile minimal --component rustfmt
|
# run: rustup install nightly --profile minimal --component rustfmt
|
||||||
|
|
||||||
- name: Check Rust files are formatted
|
# - name: Check Rust files are formatted
|
||||||
run: cargo +nightly fmt --check
|
# run: cargo +nightly fmt --check
|
||||||
|
|
||||||
fmt-toml:
|
# fmt-toml:
|
||||||
runs-on: ubuntu-latest
|
# runs-on: ubuntu-latest
|
||||||
steps:
|
# steps:
|
||||||
- uses: actions/checkout@v5
|
# - uses: actions/checkout@v5
|
||||||
with:
|
# with:
|
||||||
ref: ${{ github.head_ref }}
|
# ref: ${{ github.head_ref }}
|
||||||
|
|
||||||
- name: Install taplo-cli
|
# - name: Install taplo-cli
|
||||||
run: cargo install --locked taplo-cli
|
# run: cargo install --locked taplo-cli
|
||||||
|
|
||||||
- name: Check TOML files are formatted
|
# - name: Check TOML files are formatted
|
||||||
run: taplo fmt --check .
|
# run: taplo fmt --check .
|
||||||
|
|
||||||
machete:
|
# machete:
|
||||||
runs-on: ubuntu-latest
|
# runs-on: ubuntu-latest
|
||||||
steps:
|
# steps:
|
||||||
- uses: actions/checkout@v5
|
# - uses: actions/checkout@v5
|
||||||
with:
|
# with:
|
||||||
ref: ${{ github.head_ref }}
|
# ref: ${{ github.head_ref }}
|
||||||
|
|
||||||
- name: Install active toolchain
|
# - name: Install active toolchain
|
||||||
run: rustup install
|
# run: rustup install
|
||||||
|
|
||||||
- name: Install cargo-machete
|
# - name: Install cargo-machete
|
||||||
run: cargo install cargo-machete
|
# run: cargo install cargo-machete
|
||||||
|
|
||||||
- name: Check for unused dependencies
|
# - name: Check for unused dependencies
|
||||||
run: cargo machete
|
# run: cargo machete
|
||||||
|
|
||||||
deny:
|
# deny:
|
||||||
runs-on: ubuntu-latest
|
# runs-on: ubuntu-latest
|
||||||
steps:
|
# steps:
|
||||||
- uses: actions/checkout@v5
|
# - uses: actions/checkout@v5
|
||||||
with:
|
# with:
|
||||||
ref: ${{ github.head_ref }}
|
# ref: ${{ github.head_ref }}
|
||||||
|
|
||||||
- name: Install cargo-deny
|
# - name: Install cargo-deny
|
||||||
run: cargo install --locked cargo-deny
|
# run: cargo install --locked cargo-deny
|
||||||
|
|
||||||
- name: Check licenses and advisories
|
# - name: Check licenses and advisories
|
||||||
run: cargo deny check
|
# run: cargo deny check
|
||||||
|
|
||||||
lint:
|
# lint:
|
||||||
runs-on: ubuntu-latest
|
# runs-on: ubuntu-latest
|
||||||
timeout-minutes: 60
|
# timeout-minutes: 60
|
||||||
|
|
||||||
name: lint
|
# name: lint
|
||||||
steps:
|
# steps:
|
||||||
- uses: actions/checkout@v5
|
# - uses: actions/checkout@v5
|
||||||
with:
|
# with:
|
||||||
ref: ${{ github.head_ref }}
|
# ref: ${{ github.head_ref }}
|
||||||
|
|
||||||
- uses: ./.github/actions/install-system-deps
|
# - uses: ./.github/actions/install-system-deps
|
||||||
|
|
||||||
- uses: ./.github/actions/install-risc0
|
# - uses: ./.github/actions/install-risc0
|
||||||
|
|
||||||
- uses: ./.github/actions/install-logos-blockchain-circuits
|
# - uses: ./.github/actions/install-logos-blockchain-circuits
|
||||||
with:
|
# with:
|
||||||
github-token: ${{ secrets.GITHUB_TOKEN }}
|
# github-token: ${{ secrets.GITHUB_TOKEN }}
|
||||||
|
|
||||||
- name: Install active toolchain
|
# - name: Install active toolchain
|
||||||
run: rustup install
|
# run: rustup install
|
||||||
|
|
||||||
- name: Lint workspace
|
# - name: Lint workspace
|
||||||
env:
|
# env:
|
||||||
RISC0_SKIP_BUILD: "1"
|
# RISC0_SKIP_BUILD: "1"
|
||||||
run: cargo clippy --workspace --all-targets --all-features -- -D warnings
|
# run: cargo clippy --workspace --all-targets --all-features -- -D warnings
|
||||||
|
|
||||||
- name: Lint programs
|
# - name: Lint programs
|
||||||
env:
|
# env:
|
||||||
RISC0_SKIP_BUILD: "1"
|
# RISC0_SKIP_BUILD: "1"
|
||||||
run: cargo clippy -p "*programs" -- -D warnings
|
# run: cargo clippy -p "*programs" -- -D warnings
|
||||||
|
|
||||||
unit-tests:
|
# unit-tests:
|
||||||
runs-on: ubuntu-latest
|
# runs-on: ubuntu-latest
|
||||||
timeout-minutes: 60
|
# timeout-minutes: 60
|
||||||
steps:
|
# steps:
|
||||||
- uses: actions/checkout@v5
|
# - uses: actions/checkout@v5
|
||||||
with:
|
# with:
|
||||||
ref: ${{ github.head_ref }}
|
# ref: ${{ github.head_ref }}
|
||||||
|
|
||||||
- uses: ./.github/actions/install-system-deps
|
# - uses: ./.github/actions/install-system-deps
|
||||||
|
|
||||||
- uses: ./.github/actions/install-risc0
|
# - uses: ./.github/actions/install-risc0
|
||||||
|
|
||||||
- uses: ./.github/actions/install-logos-blockchain-circuits
|
# - uses: ./.github/actions/install-logos-blockchain-circuits
|
||||||
with:
|
# with:
|
||||||
github-token: ${{ secrets.GITHUB_TOKEN }}
|
# github-token: ${{ secrets.GITHUB_TOKEN }}
|
||||||
|
|
||||||
- name: Install active toolchain
|
# - name: Install active toolchain
|
||||||
run: rustup install
|
# run: rustup install
|
||||||
|
|
||||||
- name: Install nextest
|
# - name: Install nextest
|
||||||
run: cargo install --locked cargo-nextest
|
# run: cargo install --locked cargo-nextest
|
||||||
|
|
||||||
- name: Run tests
|
# - name: Run tests
|
||||||
env:
|
# env:
|
||||||
RISC0_DEV_MODE: "1"
|
# RISC0_DEV_MODE: "1"
|
||||||
RUST_LOG: "info"
|
# RUST_LOG: "info"
|
||||||
run: cargo nextest run --workspace --exclude integration_tests
|
# run: cargo nextest run --workspace --exclude integration_tests
|
||||||
|
|
||||||
integration-tests:
|
# integration-tests:
|
||||||
runs-on: ubuntu-latest
|
# runs-on: ubuntu-latest
|
||||||
timeout-minutes: 60
|
# timeout-minutes: 60
|
||||||
steps:
|
# steps:
|
||||||
- uses: actions/checkout@v5
|
# - uses: actions/checkout@v5
|
||||||
with:
|
# with:
|
||||||
ref: ${{ github.head_ref }}
|
# ref: ${{ github.head_ref }}
|
||||||
|
|
||||||
- uses: ./.github/actions/install-system-deps
|
# - uses: ./.github/actions/install-system-deps
|
||||||
|
|
||||||
- uses: ./.github/actions/install-risc0
|
# - uses: ./.github/actions/install-risc0
|
||||||
|
|
||||||
- uses: ./.github/actions/install-logos-blockchain-circuits
|
# - uses: ./.github/actions/install-logos-blockchain-circuits
|
||||||
with:
|
# with:
|
||||||
github-token: ${{ secrets.GITHUB_TOKEN }}
|
# github-token: ${{ secrets.GITHUB_TOKEN }}
|
||||||
|
|
||||||
- name: Install active toolchain
|
# - name: Install active toolchain
|
||||||
run: rustup install
|
# run: rustup install
|
||||||
|
|
||||||
- name: Install nextest
|
# - name: Install nextest
|
||||||
run: cargo install --locked cargo-nextest
|
# run: cargo install --locked cargo-nextest
|
||||||
|
|
||||||
- name: Run tests
|
# - name: Run tests
|
||||||
env:
|
# env:
|
||||||
RISC0_DEV_MODE: "1"
|
# RISC0_DEV_MODE: "1"
|
||||||
RUST_LOG: "info"
|
# RUST_LOG: "info"
|
||||||
run: cargo nextest run -p integration_tests -- --skip tps_test --skip indexer
|
# run: cargo nextest run -p integration_tests -- --skip tps_test --skip indexer
|
||||||
|
|
||||||
integration-tests-indexer:
|
integration-tests-indexer:
|
||||||
runs-on: ubuntu-latest
|
runs-on: ubuntu-latest
|
||||||
@ -184,53 +184,53 @@ jobs:
|
|||||||
RUST_LOG: "info"
|
RUST_LOG: "info"
|
||||||
run: cargo nextest run -p integration_tests indexer -- --skip tps_test
|
run: cargo nextest run -p integration_tests indexer -- --skip tps_test
|
||||||
|
|
||||||
valid-proof-test:
|
# valid-proof-test:
|
||||||
runs-on: ubuntu-latest
|
# runs-on: ubuntu-latest
|
||||||
timeout-minutes: 60
|
# timeout-minutes: 60
|
||||||
steps:
|
# steps:
|
||||||
- uses: actions/checkout@v5
|
# - uses: actions/checkout@v5
|
||||||
with:
|
# with:
|
||||||
ref: ${{ github.head_ref }}
|
# ref: ${{ github.head_ref }}
|
||||||
|
|
||||||
- uses: ./.github/actions/install-system-deps
|
# - uses: ./.github/actions/install-system-deps
|
||||||
|
|
||||||
- uses: ./.github/actions/install-risc0
|
# - uses: ./.github/actions/install-risc0
|
||||||
|
|
||||||
- uses: ./.github/actions/install-logos-blockchain-circuits
|
# - uses: ./.github/actions/install-logos-blockchain-circuits
|
||||||
with:
|
# with:
|
||||||
github-token: ${{ secrets.GITHUB_TOKEN }}
|
# github-token: ${{ secrets.GITHUB_TOKEN }}
|
||||||
|
|
||||||
- name: Install active toolchain
|
# - name: Install active toolchain
|
||||||
run: rustup install
|
# run: rustup install
|
||||||
|
|
||||||
- name: Test valid proof
|
# - name: Test valid proof
|
||||||
env:
|
# env:
|
||||||
RUST_LOG: "info"
|
# RUST_LOG: "info"
|
||||||
run: cargo test -p integration_tests -- --exact private::private_transfer_to_owned_account
|
# run: cargo test -p integration_tests -- --exact private::private_transfer_to_owned_account
|
||||||
|
|
||||||
artifacts:
|
# artifacts:
|
||||||
runs-on: ubuntu-latest
|
# runs-on: ubuntu-latest
|
||||||
timeout-minutes: 60
|
# timeout-minutes: 60
|
||||||
|
|
||||||
name: artifacts
|
# name: artifacts
|
||||||
steps:
|
# steps:
|
||||||
- uses: actions/checkout@v5
|
# - uses: actions/checkout@v5
|
||||||
with:
|
# with:
|
||||||
ref: ${{ github.head_ref }}
|
# ref: ${{ github.head_ref }}
|
||||||
|
|
||||||
- uses: ./.github/actions/install-risc0
|
# - uses: ./.github/actions/install-risc0
|
||||||
|
|
||||||
- name: Install just
|
# - name: Install just
|
||||||
run: cargo install just
|
# run: cargo install just
|
||||||
|
|
||||||
- name: Build artifacts
|
# - name: Build artifacts
|
||||||
run: just build-artifacts
|
# run: just build-artifacts
|
||||||
|
|
||||||
- name: Check if artifacts match repository
|
# - name: Check if artifacts match repository
|
||||||
run: |
|
# run: |
|
||||||
if ! git diff --exit-code artifacts/; then
|
# if ! git diff --exit-code artifacts/; then
|
||||||
echo "❌ Artifacts in the repository are out of date!"
|
# echo "❌ Artifacts in the repository are out of date!"
|
||||||
echo "Please run 'just build-artifacts' and commit the changes."
|
# echo "Please run 'just build-artifacts' and commit the changes."
|
||||||
exit 1
|
# exit 1
|
||||||
fi
|
# fi
|
||||||
echo "✅ Artifacts are up to date"
|
# echo "✅ Artifacts are up to date"
|
||||||
|
|||||||
@ -13,7 +13,7 @@ use tokio::test;
|
|||||||
use wallet::cli::{Command, programs::native_token_transfer::AuthTransferSubcommand};
|
use wallet::cli::{Command, programs::native_token_transfer::AuthTransferSubcommand};
|
||||||
|
|
||||||
/// Timeout in milliseconds to reliably await for block finalization.
|
/// Timeout in milliseconds to reliably await for block finalization.
|
||||||
const L2_TO_L1_TIMEOUT_MILLIS: u64 = 600_000;
|
const L2_TO_L1_TIMEOUT_MILLIS: u64 = 200_000;
|
||||||
|
|
||||||
#[test]
|
#[test]
|
||||||
async fn indexer_test_run() -> Result<()> {
|
async fn indexer_test_run() -> Result<()> {
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user