@@ -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 } ;
@@ -208,7 +209,6 @@ impl BlobFactory {
208209
209210 /// Executes the unblocked transactions and applies the changes to the state.
210211 /// Any subsequent tx added will end up in the next block.
211- #[ expect( dead_code) ]
212212 async fn close_block ( & mut self ) {
213213 let block_context = self . next_block_context ( ) ;
214214 let block_info = block_context. block_info ( ) . clone ( ) ;
@@ -359,7 +359,6 @@ impl BlobFactory {
359359 // Tx generation
360360 // =====================
361361
362- #[ expect( dead_code) ]
363362 fn boostrap_declare_tx ( & mut self , contract : FeatureContract ) {
364363 let sender_address = ExecutableDeclareTransaction :: bootstrap_address ( ) ;
365364 let sierra = contract. get_sierra ( ) ;
@@ -595,9 +594,28 @@ async fn fetch_blob_file(client: &Client) -> Vec<AerospikeBlob> {
595594
596595#[ tokio:: test]
597596async fn test_make_data ( ) {
598- let blob_factory = BlobFactory :: new ( ) ;
597+ let mut blob_factory = BlobFactory :: new ( ) ;
599598 let chain_info = OsChainInfo :: from ( & blob_factory. chain_info ) . to_hex_map ( ) ;
600- // TODO(Dori): create txs.
599+
600+ // Create the list of transactions to be included in the blobs:
601+ // 1. bootstrap declare of an ERC20 contract.
602+ // 2. bootstrap declare of an account with real validate.
603+ // TODO(Dori): the rest of the txs.
604+ // 3. deploy account (with zero fees).
605+ // 4. deploy ERC20 contract from the account (with zero fees), while minting some tokens to the
606+ // sender account.
607+ // (from this point - all txs include non-zero fees, and no more bootstrap declares)
608+ // 5. declare the test contract.
609+ // 6. deploy the test contract.
610+ // 7. deploy another instance of the test contract.
611+ // 8. invoke the test contract: something with a state change.
612+ // 9. invoke the test contract: test syscalls.
613+ let erc20_contract = FeatureContract :: ERC20 ( CairoVersion :: Cairo1 ( RunnableCairo1 :: Casm ) ) ;
614+ let account_with_real_validate = FeatureContract :: AccountWithRealValidate ( RunnableCairo1 :: Casm ) ;
615+ blob_factory. boostrap_declare_tx ( erc20_contract) ;
616+ blob_factory. close_block ( ) . await ;
617+ blob_factory. boostrap_declare_tx ( account_with_real_validate) ;
618+
601619 let ( blobs, preconfirmed_block) = blob_factory. finalize ( ) . await ;
602620 expect_file ! [ CHAIN_INFO_PATH ] . assert_eq ( & serde_json:: to_string_pretty ( & chain_info) . unwrap ( ) ) ;
603621 expect_file ! [ PRECONFIRMED_BLOCK_PATH ] . assert_eq ( & to_normalized_json ( & preconfirmed_block) ) ;
0 commit comments