@@ -29,7 +29,7 @@ use sp_runtime::{
2929use node_primitives:: { Balance , Hash } ;
3030use node_runtime:: {
3131 constants:: { currency:: * , time:: SLOT_DURATION } ,
32- Balances , Block , Call , CheckedExtrinsic , Event , Header , Runtime , System , TransactionPayment ,
32+ Balances , Call , CheckedExtrinsic , Event , Header , Runtime , System , TransactionPayment ,
3333 UncheckedExtrinsic ,
3434} ;
3535use node_testing:: keyring:: * ;
@@ -78,7 +78,7 @@ fn set_heap_pages<E: Externalities>(ext: &mut E, heap_pages: u64) {
7878fn changes_trie_block ( ) -> ( Vec < u8 > , Hash ) {
7979 let time = 42 * 1000 ;
8080 construct_block (
81- & mut new_test_ext ( compact_code_unwrap ( ) , true ) ,
81+ & mut new_test_ext ( compact_code_unwrap ( ) ) ,
8282 1 ,
8383 GENESIS_HASH . into ( ) ,
8484 vec ! [
@@ -102,7 +102,7 @@ fn changes_trie_block() -> (Vec<u8>, Hash) {
102102/// are not guaranteed to be deterministic) and to ensure that the correct state is propagated
103103/// from block1's execution to block2 to derive the correct storage_root.
104104fn blocks ( ) -> ( ( Vec < u8 > , Hash ) , ( Vec < u8 > , Hash ) ) {
105- let mut t = new_test_ext ( compact_code_unwrap ( ) , false ) ;
105+ let mut t = new_test_ext ( compact_code_unwrap ( ) ) ;
106106 let time1 = 42 * 1000 ;
107107 let block1 = construct_block (
108108 & mut t,
@@ -160,7 +160,7 @@ fn blocks() -> ((Vec<u8>, Hash), (Vec<u8>, Hash)) {
160160
161161fn block_with_size ( time : u64 , nonce : u32 , size : usize ) -> ( Vec < u8 > , Hash ) {
162162 construct_block (
163- & mut new_test_ext ( compact_code_unwrap ( ) , false ) ,
163+ & mut new_test_ext ( compact_code_unwrap ( ) ) ,
164164 1 ,
165165 GENESIS_HASH . into ( ) ,
166166 vec ! [
@@ -179,7 +179,7 @@ fn block_with_size(time: u64, nonce: u32, size: usize) -> (Vec<u8>, Hash) {
179179
180180#[ test]
181181fn panic_execution_with_foreign_code_gives_error ( ) {
182- let mut t = new_test_ext ( bloaty_code_unwrap ( ) , false ) ;
182+ let mut t = new_test_ext ( bloaty_code_unwrap ( ) ) ;
183183 t. insert (
184184 <frame_system:: Account < Runtime > >:: hashed_key_for ( alice ( ) ) ,
185185 ( 69u128 , 0u32 , 0u128 , 0u128 , 0u128 ) . encode ( ) ,
@@ -211,7 +211,7 @@ fn panic_execution_with_foreign_code_gives_error() {
211211
212212#[ test]
213213fn bad_extrinsic_with_native_equivalent_code_gives_error ( ) {
214- let mut t = new_test_ext ( compact_code_unwrap ( ) , false ) ;
214+ let mut t = new_test_ext ( compact_code_unwrap ( ) ) ;
215215 t. insert (
216216 <frame_system:: Account < Runtime > >:: hashed_key_for ( alice ( ) ) ,
217217 ( 0u32 , 0u32 , 0u32 , 69u128 , 0u128 , 0u128 , 0u128 ) . encode ( ) ,
@@ -243,7 +243,7 @@ fn bad_extrinsic_with_native_equivalent_code_gives_error() {
243243
244244#[ test]
245245fn successful_execution_with_native_equivalent_code_gives_ok ( ) {
246- let mut t = new_test_ext ( compact_code_unwrap ( ) , false ) ;
246+ let mut t = new_test_ext ( compact_code_unwrap ( ) ) ;
247247 t. insert (
248248 <frame_system:: Account < Runtime > >:: hashed_key_for ( alice ( ) ) ,
249249 AccountInfo :: < <Runtime as frame_system:: Config >:: Index , _ > {
@@ -296,7 +296,7 @@ fn successful_execution_with_native_equivalent_code_gives_ok() {
296296
297297#[ test]
298298fn successful_execution_with_foreign_code_gives_ok ( ) {
299- let mut t = new_test_ext ( bloaty_code_unwrap ( ) , false ) ;
299+ let mut t = new_test_ext ( bloaty_code_unwrap ( ) ) ;
300300 t. insert (
301301 <frame_system:: Account < Runtime > >:: hashed_key_for ( alice ( ) ) ,
302302 AccountInfo :: < <Runtime as frame_system:: Config >:: Index , _ > {
@@ -349,7 +349,7 @@ fn successful_execution_with_foreign_code_gives_ok() {
349349
350350#[ test]
351351fn full_native_block_import_works ( ) {
352- let mut t = new_test_ext ( compact_code_unwrap ( ) , false ) ;
352+ let mut t = new_test_ext ( compact_code_unwrap ( ) ) ;
353353
354354 let ( block1, block2) = blocks ( ) ;
355355
@@ -529,7 +529,7 @@ fn full_native_block_import_works() {
529529
530530#[ test]
531531fn full_wasm_block_import_works ( ) {
532- let mut t = new_test_ext ( compact_code_unwrap ( ) , false ) ;
532+ let mut t = new_test_ext ( compact_code_unwrap ( ) ) ;
533533
534534 let ( block1, block2) = blocks ( ) ;
535535
@@ -679,7 +679,7 @@ fn deploying_wasm_contract_should_work() {
679679
680680 let time = 42 * 1000 ;
681681 let b = construct_block (
682- & mut new_test_ext ( compact_code_unwrap ( ) , false ) ,
682+ & mut new_test_ext ( compact_code_unwrap ( ) ) ,
683683 1 ,
684684 GENESIS_HASH . into ( ) ,
685685 vec ! [
@@ -712,7 +712,7 @@ fn deploying_wasm_contract_should_work() {
712712 ( time / SLOT_DURATION ) . into ( ) ,
713713 ) ;
714714
715- let mut t = new_test_ext ( compact_code_unwrap ( ) , false ) ;
715+ let mut t = new_test_ext ( compact_code_unwrap ( ) ) ;
716716
717717 executor_call :: < NeverNativeValue , fn ( ) -> _ > ( & mut t, "Core_execute_block" , & b. 0 , false , None )
718718 . 0
@@ -727,7 +727,7 @@ fn deploying_wasm_contract_should_work() {
727727
728728#[ test]
729729fn wasm_big_block_import_fails ( ) {
730- let mut t = new_test_ext ( compact_code_unwrap ( ) , false ) ;
730+ let mut t = new_test_ext ( compact_code_unwrap ( ) ) ;
731731
732732 set_heap_pages ( & mut t. ext ( ) , 4 ) ;
733733
@@ -744,7 +744,7 @@ fn wasm_big_block_import_fails() {
744744
745745#[ test]
746746fn native_big_block_import_succeeds ( ) {
747- let mut t = new_test_ext ( compact_code_unwrap ( ) , false ) ;
747+ let mut t = new_test_ext ( compact_code_unwrap ( ) ) ;
748748
749749 executor_call :: < NeverNativeValue , fn ( ) -> _ > (
750750 & mut t,
@@ -759,7 +759,7 @@ fn native_big_block_import_succeeds() {
759759
760760#[ test]
761761fn native_big_block_import_fails_on_fallback ( ) {
762- let mut t = new_test_ext ( compact_code_unwrap ( ) , false ) ;
762+ let mut t = new_test_ext ( compact_code_unwrap ( ) ) ;
763763
764764 // We set the heap pages to 8 because we know that should give an OOM in WASM with the given
765765 // block.
@@ -778,7 +778,7 @@ fn native_big_block_import_fails_on_fallback() {
778778
779779#[ test]
780780fn panic_execution_gives_error ( ) {
781- let mut t = new_test_ext ( bloaty_code_unwrap ( ) , false ) ;
781+ let mut t = new_test_ext ( bloaty_code_unwrap ( ) ) ;
782782 t. insert (
783783 <frame_system:: Account < Runtime > >:: hashed_key_for ( alice ( ) ) ,
784784 AccountInfo :: < <Runtime as frame_system:: Config >:: Index , _ > {
@@ -815,7 +815,7 @@ fn panic_execution_gives_error() {
815815
816816#[ test]
817817fn successful_execution_gives_ok ( ) {
818- let mut t = new_test_ext ( compact_code_unwrap ( ) , false ) ;
818+ let mut t = new_test_ext ( compact_code_unwrap ( ) ) ;
819819 t. insert (
820820 <frame_system:: Account < Runtime > >:: hashed_key_for ( alice ( ) ) ,
821821 AccountInfo :: < <Runtime as frame_system:: Config >:: Index , _ > {
@@ -874,44 +874,6 @@ fn successful_execution_gives_ok() {
874874 } ) ;
875875}
876876
877- #[ test]
878- fn full_native_block_import_works_with_changes_trie ( ) {
879- let block1 = changes_trie_block ( ) ;
880- let block_data = block1. 0 ;
881- let block = Block :: decode ( & mut & block_data[ ..] ) . unwrap ( ) ;
882-
883- let mut t = new_test_ext ( compact_code_unwrap ( ) , true ) ;
884- executor_call :: < NeverNativeValue , fn ( ) -> _ > (
885- & mut t,
886- "Core_execute_block" ,
887- & block. encode ( ) ,
888- true ,
889- None ,
890- )
891- . 0
892- . unwrap ( ) ;
893-
894- assert ! ( t. ext( ) . storage_changes_root( & GENESIS_HASH ) . unwrap( ) . is_some( ) ) ;
895- }
896-
897- #[ test]
898- fn full_wasm_block_import_works_with_changes_trie ( ) {
899- let block1 = changes_trie_block ( ) ;
900-
901- let mut t = new_test_ext ( compact_code_unwrap ( ) , true ) ;
902- executor_call :: < NeverNativeValue , fn ( ) -> _ > (
903- & mut t,
904- "Core_execute_block" ,
905- & block1. 0 ,
906- false ,
907- None ,
908- )
909- . 0
910- . unwrap ( ) ;
911-
912- assert ! ( t. ext( ) . storage_changes_root( & GENESIS_HASH ) . unwrap( ) . is_some( ) ) ;
913- }
914-
915877#[ test]
916878fn should_import_block_with_test_client ( ) {
917879 use node_testing:: client:: {
0 commit comments