@@ -33,6 +33,7 @@ use blockifier::test_utils::dict_state_reader::DictStateReader;
3333use blockifier:: transaction:: account_transaction:: AccountTransaction as BlockifierAccountTx ;
3434use blockifier:: transaction:: transaction_execution:: Transaction as BlockifierTx ;
3535use blockifier:: transaction:: transactions:: ExecutableTransaction ;
36+ use blockifier_test_utils:: cairo_versions:: { CairoVersion , RunnableCairo1 } ;
3637use blockifier_test_utils:: contracts:: FeatureContract ;
3738use expect_test:: expect_file;
3839use google_cloud_storage:: client:: { Client , ClientConfig } ;
@@ -215,7 +216,6 @@ impl BlobFactory {
215216
216217 /// Executes the unblocked transactions and applies the changes to the state.
217218 /// Any subsequent transaction added will end up in the next block.
218- #[ expect( dead_code) ]
219219 async fn close_block ( & mut self ) {
220220 let block_context = self . next_block_context ( ) ;
221221 let block_info = block_context. block_info ( ) . clone ( ) ;
@@ -362,7 +362,6 @@ impl BlobFactory {
362362 // Tx generation
363363 // =====================
364364
365- #[ expect( dead_code) ]
366365 fn boostrap_declare_tx ( & mut self , contract : FeatureContract ) {
367366 let sender_address = ExecutableDeclareTx :: bootstrap_address ( ) ;
368367 let sierra = contract. get_sierra ( ) ;
@@ -601,9 +600,28 @@ async fn fetch_blob_file(client: &Client) -> Vec<AerospikeBlob> {
601600
602601#[ tokio:: test]
603602async fn test_make_data ( ) {
604- let blob_factory = BlobFactory :: new ( ) ;
603+ let mut blob_factory = BlobFactory :: new ( ) ;
605604 let chain_info = OsChainInfo :: from ( & blob_factory. chain_info ) . to_hex_map ( ) ;
606- // TODO(Dori): create txs.
605+
606+ // Create the list of transactions to be included in the blobs:
607+ // 1. bootstrap declare of an ERC20 contract.
608+ // 2. bootstrap declare of an account with real validate.
609+ // TODO(Dori): the rest of the txs.
610+ // 3. deploy account (with zero fees).
611+ // 4. deploy ERC20 contract from the account (with zero fees), while minting some tokens to the
612+ // sender account.
613+ // (from this point - all txs include non-zero fees, and no more bootstrap declares)
614+ // 5. declare the test contract.
615+ // 6. deploy the test contract.
616+ // 7. deploy another instance of the test contract.
617+ // 8. invoke the test contract: something with a state change.
618+ // 9. invoke the test contract: test syscalls.
619+ let erc20_contract = FeatureContract :: ERC20 ( CairoVersion :: Cairo1 ( RunnableCairo1 :: Casm ) ) ;
620+ let account_with_real_validate = FeatureContract :: AccountWithRealValidate ( RunnableCairo1 :: Casm ) ;
621+ blob_factory. boostrap_declare_tx ( erc20_contract) ;
622+ blob_factory. close_block ( ) . await ;
623+ blob_factory. boostrap_declare_tx ( account_with_real_validate) ;
624+
607625 let ( blobs, preconfirmed_block) = blob_factory. finalize ( ) . await ;
608626 expect_file ! [ CHAIN_INFO_PATH ] . assert_eq ( & serde_json:: to_string_pretty ( & chain_info) . unwrap ( ) ) ;
609627 expect_file ! [ PRECONFIRMED_BLOCK_PATH ] . assert_eq ( & to_normalized_json ( & preconfirmed_block) ) ;
0 commit comments