@@ -2432,6 +2432,18 @@ where
24322432 let client2 = builder. add_initial_chain ( description2, Amount :: ONE ) . await ?;
24332433 let client3 = builder. add_initial_chain ( description3, Amount :: ONE ) . await ?;
24342434
2435+ // Configure the clients as super owners, so they make fast blocks by default.
2436+ for client in [ & client1, & client2, & client3] {
2437+ let pub_key = client. public_key ( ) . await ?;
2438+ let owner_change_op = Operation :: System ( SystemOperation :: ChangeOwnership {
2439+ super_owners : vec ! [ pub_key] ,
2440+ owners : vec ! [ ] ,
2441+ multi_leader_rounds : 10 ,
2442+ timeout_config : TimeoutConfig :: default ( ) ,
2443+ } ) ;
2444+ client. execute_operation ( owner_change_op. clone ( ) ) . await ?;
2445+ }
2446+
24352447 // Take one validator down
24362448 builder. set_fault_type ( [ 3 ] , FaultType :: Offline ) . await ;
24372449
@@ -2440,19 +2452,21 @@ where
24402452 CryptoHash :: new ( & BlobBytes ( blob_bytes. clone ( ) ) ) ,
24412453 BlobType :: Data ,
24422454 ) ;
2443- client1
2455+ let certificate = client1
24442456 . publish_data_blob ( blob_bytes)
24452457 . await
24462458 . unwrap ( )
24472459 . unwrap ( ) ;
2460+ assert_eq ! ( certificate. round, Round :: Fast ) ;
24482461
24492462 // Send a message from chain 2 to chain 3.
2450- client2
2463+ let certificate = client2
24512464 . transfer ( None , Amount :: from_millis ( 1 ) , Recipient :: chain ( chain_id3) )
24522465 . await
24532466 . unwrap ( )
24542467 . unwrap ( ) ;
24552468 client3. synchronize_from_validators ( ) . await . unwrap ( ) ;
2469+ assert_eq ! ( certificate. round, Round :: Fast ) ;
24562470
24572471 builder. set_fault_type ( [ 2 ] , FaultType :: Offline ) . await ;
24582472 builder. set_fault_type ( [ 3 ] , FaultType :: Honest ) . await ;
@@ -2463,6 +2477,8 @@ where
24632477 . await
24642478 . unwrap ( )
24652479 . unwrap ( ) ;
2480+ // This read a new blob, so it cannot be a fast block.
2481+ assert_eq ! ( certificate. round, Round :: MultiLeader ( 0 ) ) ;
24662482 let executed_block = certificate. executed_block ( ) ;
24672483 assert_eq ! ( executed_block. block. incoming_bundles. len( ) , 1 ) ;
24682484 assert_eq ! ( executed_block. required_blob_ids( ) . len( ) , 1 ) ;
0 commit comments