Skip to content
This repository has been archived by the owner on Jul 5, 2024. It is now read-only.

Commit

Permalink
add a test to make sure unusable rows are unchanged
Browse files Browse the repository at this point in the history
  • Loading branch information
ChihChengLiang committed Jan 31, 2024
1 parent 70202bb commit 1d9dc05
Showing 1 changed file with 13 additions and 2 deletions.
15 changes: 13 additions & 2 deletions zkevm-circuits/src/evm_circuit.rs
Original file line number Diff line number Diff line change
Expand Up @@ -476,9 +476,20 @@ mod evm_circuit_stats {

#[test]
fn evm_circuit_unusable_rows() {
let computed = EvmCircuit::<Fr>::unusable_rows();
let mainnet_config = FeatureConfig::default();
let invalid_tx_config = FeatureConfig {
invalid_tx: true,
..Default::default()
};

assert_eq!(
computed,
unusable_rows::<Fr, EvmCircuit::<Fr>>(mainnet_config),
);
assert_eq!(
EvmCircuit::<Fr>::unusable_rows(),
unusable_rows::<Fr, EvmCircuit::<Fr>>(FeatureConfig::default()),
computed,
unusable_rows::<Fr, EvmCircuit::<Fr>>(invalid_tx_config),
)
}

Expand Down

0 comments on commit 1d9dc05

Please sign in to comment.