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

Commit 847292b

Browse files
committed
enable unittest for challenge aggregation circuit
1 parent ac68a13 commit 847292b

File tree

1 file changed

+2
-22
lines changed
  • zkevm-circuits/src/root_circuit

1 file changed

+2
-22
lines changed

zkevm-circuits/src/root_circuit/test.rs

Lines changed: 2 additions & 22 deletions
Original file line numberDiff line numberDiff line change
@@ -9,8 +9,7 @@ use crate::{
99
table::{
1010
self, rw_table::get_rwtable_cols_commitment, AccountFieldTag, LookupTable, TxLogFieldTag,
1111
},
12-
util::{self},
13-
witness::{Rw, RwRow},
12+
witness::Rw,
1413
};
1514
use bus_mapping::circuit_input_builder::FixedCParams;
1615
use eth_types::{address, Address, Field, U256};
@@ -32,7 +31,6 @@ use itertools::Itertools;
3231
use rand::rngs::OsRng;
3332
use snark_verifier::util::transcript::Transcript;
3433
use table::RwTable;
35-
use util::word::WordLoHi;
3634

3735
struct RwTableCircuit<'a> {
3836
rws: &'a [Rw],
@@ -100,32 +98,14 @@ impl<'a, F: Field> Circuit<F> for RwTableCircuit<'a> {
10098
self.prev_chunk_last_rw,
10199
);
102100
config.enable.enable(&mut region, 0)?;
103-
// avoid empty column cause commitment value as identity point
104-
// assign rwtable.id=1 to make dummy gate work
105-
config.rw_table.assign(
106-
&mut region,
107-
0,
108-
&RwRow {
109-
rw_counter: Value::known(F::ONE),
110-
is_write: Value::known(F::ONE),
111-
tag: Value::known(F::ONE),
112-
id: Value::known(F::ONE),
113-
address: Value::known(F::ONE),
114-
field_tag: Value::known(F::ONE),
115-
storage_key: WordLoHi::new([F::ONE, F::ONE]).into_value(),
116-
value: WordLoHi::new([F::ONE, F::ONE]).into_value(),
117-
value_prev: WordLoHi::new([F::ONE, F::ONE]).into_value(),
118-
init_val: WordLoHi::new([F::ONE, F::ONE]).into_value(),
119-
},
120-
)
101+
Ok(())
121102
},
122103
)?;
123104
Ok(())
124105
}
125106
}
126107

127108
#[test]
128-
#[ignore]
129109
fn test_user_challenge_aggregation() {
130110
let num_challenges = 1;
131111
let k = 12;

0 commit comments

Comments
 (0)