Skip to content

Commit

Permalink
Add basic CI
Browse files Browse the repository at this point in the history
  • Loading branch information
popzxc committed Aug 15, 2024
1 parent b02c383 commit 9d10367
Show file tree
Hide file tree
Showing 4 changed files with 67 additions and 1 deletion.
58 changes: 58 additions & 0 deletions .github/workflows/ci.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,58 @@
name: "Rust CI"
on:
pull_request:

jobs:
build:
name: cargo build
runs-on: [ubuntu-22.04-github-hosted-32core]
steps:
- uses: actions/checkout@v3
- uses: actions-rust-lang/setup-rust-toolchain@v1
with:
rustflags: ""
- name: Setup rust
run: |
rustup set profile minimal
rustup toolchain install nightly-2023-08-23
rustup default nightly-2023-08-23
cargo install cargo-nextest
- name: Compile
run: cargo build

test:
name: cargo test
runs-on: [ubuntu-22.04-github-hosted-32core]
needs: build
steps:
- uses: actions/checkout@v3
- uses: actions-rust-lang/setup-rust-toolchain@v1
with:
rustflags: ""
- name: Setup rust
run: |
rustup set profile minimal
rustup toolchain install nightly-2023-08-23
rustup default nightly-2023-08-23
cargo install cargo-nextest
- name: zkevm_test_harness - Main test
run: cargo nextest run --release --manifest-path crates/zkevm_test_harness/Cargo.toml --test-threads 2
- name: Encodings test
run: cargo nextest run --release --manifest-path crates/circuit_encodings/Cargo.toml
- name: Api tests
run: cargo nextest run --release --manifest-path crates/circuit_sequencer_api/Cargo.toml
- name: Definitions test
run: cargo nextest run --release --manifest-path crates/circuit_definitions/Cargo.toml
- name: Kzg tests
run: cargo nextest run --release --manifest-path crates/kzg/Cargo.toml

formatting:
name: cargo fmt
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- uses: actions-rust-lang/setup-rust-toolchain@v1
with:
components: rustfmt
- name: Rustfmt Check
uses: actions-rust-lang/rustfmt@v1
8 changes: 8 additions & 0 deletions .github/workflows/deny.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
name: Cargo deny check
on: pull_request
jobs:
cargo-deny:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- uses: EmbarkStudios/cargo-deny-action@v1
2 changes: 1 addition & 1 deletion crates/zkevm_opcode_defs/src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -27,8 +27,8 @@ pub use sha3;
pub use self::definitions::*;
pub use self::imm_mem_modifiers::*;
pub use self::opcode::*;
pub use self::utils::*;
pub use self::system_params::*;
pub use self::utils::*;

use lazy_static::lazy_static;

Expand Down
File renamed without changes.

0 comments on commit 9d10367

Please sign in to comment.