File tree Expand file tree Collapse file tree 1 file changed +10
-13
lines changed
test/subspace-farmerless-dev-node/src Expand file tree Collapse file tree 1 file changed +10
-13
lines changed Original file line number Diff line number Diff line change @@ -137,21 +137,18 @@ async fn produce_single_block(
137137 consensus : & mut MockConsensusNode ,
138138 wait_for_bundle : bool ,
139139) -> Result < ( ) , String > {
140+ let slot = consensus. produce_slot ( ) ;
141+
140142 if wait_for_bundle {
141- let ( slot, _) = consensus
142- . produce_slot_and_wait_for_bundle_submission ( )
143- . await ;
144- consensus
145- . produce_block_with_slot ( slot)
146- . await
147- . map_err ( |err| err. to_string ( ) )
148- } else {
149- let slot = consensus. produce_slot ( ) ;
150- consensus
151- . produce_block_with_slot ( slot)
152- . await
153- . map_err ( |err| err. to_string ( ) )
143+ // Notify domain operator about the new slot and try to get a bundle
144+ // If no bundle is available, we'll produce the block anyway
145+ let _ = consensus. notify_new_slot_and_wait_for_bundle ( slot) . await ;
154146 }
147+
148+ consensus
149+ . produce_block_with_slot ( slot)
150+ . await
151+ . map_err ( |err| err. to_string ( ) )
155152}
156153
157154async fn produce_multiple_blocks (
You can’t perform that action at this time.
0 commit comments