@@ -731,7 +731,8 @@ fn test_prove_elfs_test_commit_4() {
731731 "Public output should match committed bytes"
732732 ) ;
733733
734- let mut traces = Traces :: from_elf_and_logs ( & elf, & result. logs , & Default :: default ( ) , & [ ] ) . unwrap ( ) ;
734+ let mut traces =
735+ Traces :: from_elf_and_logs ( & elf, & result. logs , & Default :: default ( ) , & [ ] ) . unwrap ( ) ;
735736 assert_eq ! (
736737 traces. public_output_bytes,
737738 result. return_values. memory_values
@@ -756,7 +757,8 @@ fn test_prove_elfs_test_commit_4_wrong_pages_rejected() {
756757 let executor =
757758 executor:: vm:: execution:: Executor :: new ( & elf, vec ! [ ] ) . expect ( "Failed to create executor" ) ;
758759 let result = executor. run ( ) . expect ( "Failed to run program" ) ;
759- let mut traces = Traces :: from_elf_and_logs ( & elf, & result. logs , & Default :: default ( ) , & [ ] ) . unwrap ( ) ;
760+ let mut traces =
761+ Traces :: from_elf_and_logs ( & elf, & result. logs , & Default :: default ( ) , & [ ] ) . unwrap ( ) ;
760762
761763 // Prover uses correct page configs
762764 let table_counts = traces. table_counts ( ) ;
@@ -801,8 +803,9 @@ fn test_prove_elfs_test_commit_4_wrong_pages_rejected() {
801803fn test_verify_rejects_tampered_public_output ( ) {
802804 let elf_bytes = crate :: test_utils:: asm_elf_bytes ( "test_commit_4" ) ;
803805 let proof_options = ProofOptions :: default_test_options ( ) ;
804- let vm_proof = crate :: prove_with_options ( & elf_bytes, vec ! [ ] , & proof_options, & Default :: default ( ) )
805- . expect ( "Prover should succeed for test_commit_4" ) ;
806+ let vm_proof =
807+ crate :: prove_with_options ( & elf_bytes, vec ! [ ] , & proof_options, & Default :: default ( ) )
808+ . expect ( "Prover should succeed for test_commit_4" ) ;
806809 assert ! (
807810 crate :: verify_with_options( & vm_proof, & elf_bytes, & proof_options)
808811 . expect( "Valid commit proof should verify" ) ,
@@ -1477,7 +1480,8 @@ fn test_deep_stack_runtime_pages_roundtrip() {
14771480 let executor =
14781481 executor:: vm:: execution:: Executor :: new ( & elf, vec ! [ ] ) . expect ( "Failed to create executor" ) ;
14791482 let result = executor. run ( ) . expect ( "Failed to run program" ) ;
1480- let mut traces = Traces :: from_elf_and_logs ( & elf, & result. logs , & Default :: default ( ) , & [ ] ) . unwrap ( ) ;
1483+ let mut traces =
1484+ Traces :: from_elf_and_logs ( & elf, & result. logs , & Default :: default ( ) , & [ ] ) . unwrap ( ) ;
14811485
14821486 let runtime_page_ranges = traces. runtime_page_ranges ( ) ;
14831487 let table_counts = traces. table_counts ( ) ;
@@ -1499,7 +1503,8 @@ fn test_deep_stack_runtime_pages_roundtrip() {
14991503 )
15001504 . expect ( "Prover failed" ) ;
15011505 // Verifier reconstructs from ELF + runtime_page_ranges hint
1502- let verifier_configs = Traces :: page_configs_from_elf_and_runtime ( & elf, & runtime_page_ranges, & [ ] ) ;
1506+ let verifier_configs =
1507+ Traces :: page_configs_from_elf_and_runtime ( & elf, & runtime_page_ranges, & [ ] ) ;
15031508 let verifier_airs =
15041509 crate :: VmAirs :: new ( & elf, & proof_options, true , & verifier_configs, & table_counts) ;
15051510 let verifier_air_refs = verifier_airs. air_refs ( ) ;
@@ -1536,7 +1541,8 @@ fn test_deep_stack_missing_pages_rejected() {
15361541 let executor =
15371542 executor:: vm:: execution:: Executor :: new ( & elf, vec ! [ ] ) . expect ( "Failed to create executor" ) ;
15381543 let result = executor. run ( ) . expect ( "Failed to run program" ) ;
1539- let mut traces = Traces :: from_elf_and_logs ( & elf, & result. logs , & Default :: default ( ) , & [ ] ) . unwrap ( ) ;
1544+ let mut traces =
1545+ Traces :: from_elf_and_logs ( & elf, & result. logs , & Default :: default ( ) , & [ ] ) . unwrap ( ) ;
15401546
15411547 // Prover uses correct page configs (auto-detected from MemoryState)
15421548 let table_counts = traces. table_counts ( ) ;
@@ -1614,7 +1620,8 @@ fn test_heap_alloc_runtime_pages_roundtrip() {
16141620 let executor =
16151621 executor:: vm:: execution:: Executor :: new ( & elf, vec ! [ ] ) . expect ( "Failed to create executor" ) ;
16161622 let result = executor. run ( ) . expect ( "Failed to run program" ) ;
1617- let mut traces = Traces :: from_elf_and_logs ( & elf, & result. logs , & Default :: default ( ) , & [ ] ) . unwrap ( ) ;
1623+ let mut traces =
1624+ Traces :: from_elf_and_logs ( & elf, & result. logs , & Default :: default ( ) , & [ ] ) . unwrap ( ) ;
16181625
16191626 let runtime_page_ranges = traces. runtime_page_ranges ( ) ;
16201627 let table_counts = traces. table_counts ( ) ;
@@ -1640,7 +1647,8 @@ fn test_heap_alloc_runtime_pages_roundtrip() {
16401647 )
16411648 . expect ( "Prover failed" ) ;
16421649 // Verifier reconstructs from ELF + runtime hint (ranges decoded to pages)
1643- let verifier_configs = Traces :: page_configs_from_elf_and_runtime ( & elf, & runtime_page_ranges, & [ ] ) ;
1650+ let verifier_configs =
1651+ Traces :: page_configs_from_elf_and_runtime ( & elf, & runtime_page_ranges, & [ ] ) ;
16441652 let verifier_airs =
16451653 crate :: VmAirs :: new ( & elf, & proof_options, true , & verifier_configs, & table_counts) ;
16461654 let verifier_air_refs = verifier_airs. air_refs ( ) ;
@@ -1696,8 +1704,9 @@ fn test_verify_rejects_zero_table_counts() {
16961704 let elf_bytes = crate :: test_utils:: asm_elf_bytes ( "sub" ) ;
16971705 let proof_options = ProofOptions :: default_test_options ( ) ;
16981706
1699- let vm_proof = crate :: prove_with_options ( & elf_bytes, vec ! [ ] , & proof_options, & Default :: default ( ) )
1700- . expect ( "Prover should succeed on valid program" ) ;
1707+ let vm_proof =
1708+ crate :: prove_with_options ( & elf_bytes, vec ! [ ] , & proof_options, & Default :: default ( ) )
1709+ . expect ( "Prover should succeed on valid program" ) ;
17011710
17021711 assert ! (
17031712 crate :: verify_with_options( & vm_proof, & elf_bytes, & proof_options)
@@ -1731,8 +1740,9 @@ fn test_verify_rejects_zero_cpu_count() {
17311740 let elf_bytes = crate :: test_utils:: asm_elf_bytes ( "sub" ) ;
17321741 let proof_options = ProofOptions :: default_test_options ( ) ;
17331742
1734- let vm_proof = crate :: prove_with_options ( & elf_bytes, vec ! [ ] , & proof_options, & Default :: default ( ) )
1735- . expect ( "Prover should succeed on valid program" ) ;
1743+ let vm_proof =
1744+ crate :: prove_with_options ( & elf_bytes, vec ! [ ] , & proof_options, & Default :: default ( ) )
1745+ . expect ( "Prover should succeed on valid program" ) ;
17361746
17371747 let tampered_proof = crate :: VmProof {
17381748 table_counts : crate :: TableCounts {
@@ -1752,8 +1762,9 @@ fn test_verify_rejects_zero_memw_count() {
17521762 let elf_bytes = crate :: test_utils:: asm_elf_bytes ( "sub" ) ;
17531763 let proof_options = ProofOptions :: default_test_options ( ) ;
17541764
1755- let vm_proof = crate :: prove_with_options ( & elf_bytes, vec ! [ ] , & proof_options, & Default :: default ( ) )
1756- . expect ( "Prover should succeed on valid program" ) ;
1765+ let vm_proof =
1766+ crate :: prove_with_options ( & elf_bytes, vec ! [ ] , & proof_options, & Default :: default ( ) )
1767+ . expect ( "Prover should succeed on valid program" ) ;
17571768
17581769 let tampered_proof = crate :: VmProof {
17591770 table_counts : crate :: TableCounts {
@@ -1879,8 +1890,9 @@ fn test_verify_rejects_inflated_table_counts() {
18791890 let elf_bytes = crate :: test_utils:: asm_elf_bytes ( "sub" ) ;
18801891 let proof_options = ProofOptions :: default_test_options ( ) ;
18811892
1882- let vm_proof = crate :: prove_with_options ( & elf_bytes, vec ! [ ] , & proof_options, & Default :: default ( ) )
1883- . expect ( "Prover should succeed on valid program" ) ;
1893+ let vm_proof =
1894+ crate :: prove_with_options ( & elf_bytes, vec ! [ ] , & proof_options, & Default :: default ( ) )
1895+ . expect ( "Prover should succeed on valid program" ) ;
18841896
18851897 // Inflate cpu count — total won't match proof.proofs.len()
18861898 let tampered_proof = crate :: VmProof {
@@ -1937,10 +1949,14 @@ fn test_prove_private_input_xpage() {
19371949fn test_prove_private_input_different_values ( ) {
19381950 let elf_bytes = crate :: test_utils:: asm_elf_bytes ( "test_private_input_xpage" ) ;
19391951 let input: Vec < u8 > = vec ! [
1940- 0xAA , 0xBB , 0xCC , 0xDD , 0xEE , 0xFF , 0x11 , 0x22 , 0x33 , 0x44 , 0x55 , 0x66 , 0x77 , 0x88 , 0x99 , 0x00 ,
1952+ 0xAA , 0xBB , 0xCC , 0xDD , 0xEE , 0xFF , 0x11 , 0x22 , 0x33 , 0x44 , 0x55 , 0x66 , 0x77 , 0x88 , 0x99 ,
1953+ 0x00 ,
19411954 ] ;
19421955 let proof = crate :: prove_with_input ( & elf_bytes, input. clone ( ) ) . expect ( "prove" ) ;
1943- assert ! ( crate :: verify( & proof, & elf_bytes) . expect( "verify" ) , "proof should verify" ) ;
1956+ assert ! (
1957+ crate :: verify( & proof, & elf_bytes) . expect( "verify" ) ,
1958+ "proof should verify"
1959+ ) ;
19441960 // ASM commits 8 bytes starting at 0xFF000008 = input[4..12]
19451961 assert_eq ! ( proof. public_output, input[ 4 ..12 ] . to_vec( ) ) ;
19461962}
@@ -2049,8 +2065,9 @@ fn test_prove_ethrex_empty_block() {
20492065 . parent ( )
20502066 . unwrap ( )
20512067 . to_path_buf ( ) ;
2052- let elf_bytes = std:: fs:: read ( workspace_root. join ( "executor/program_artifacts/rust/ethrex.elf" ) )
2053- . expect ( "need ethrex.elf" ) ;
2068+ let elf_bytes =
2069+ std:: fs:: read ( workspace_root. join ( "executor/program_artifacts/rust/ethrex.elf" ) )
2070+ . expect ( "need ethrex.elf" ) ;
20542071 let input =
20552072 std:: fs:: read ( workspace_root. join ( "executor/tests/ethrex_empty_block.bin" ) ) . unwrap ( ) ;
20562073 let proof = crate :: prove_with_input ( & elf_bytes, input) . expect ( "prove" ) ;
0 commit comments