@@ -186,7 +186,7 @@ fn buffer_fail_authority_not_signer() {
186186fn buffer_success ( ) {
187187 let mollusk = setup ( ) ;
188188
189- let buffer = Pubkey :: new_unique ( ) ;
189+ let buffer = Pubkey :: new_from_array ( [ 1 ; 32 ] ) ; // Consistent CUs when logging.
190190 let destination = Pubkey :: new_unique ( ) ;
191191 let authority = Pubkey :: new_unique ( ) ;
192192
@@ -213,6 +213,7 @@ fn buffer_success() {
213213 ] ,
214214 & [
215215 Check :: success ( ) ,
216+ Check :: compute_units ( 12_793 ) ,
216217 // Closed, but still owned by the loader.
217218 Check :: account ( & buffer)
218219 . data ( & [ 0 , 0 , 0 , 0 ] ) // Size of Uninitialized.
@@ -433,9 +434,7 @@ fn programdata_fail_incorrect_authority() {
433434 ) ,
434435 ) ,
435436 ] ,
436- & [
437- Check :: err ( ProgramError :: IncorrectAuthority ) ,
438- ] ,
437+ & [ Check :: err ( ProgramError :: IncorrectAuthority ) ] ,
439438 ) ;
440439}
441440
@@ -491,7 +490,7 @@ fn programdata_success() {
491490
492491 let destination = Pubkey :: new_unique ( ) ;
493492 let authority = Pubkey :: new_unique ( ) ;
494- let program = Pubkey :: new_unique ( ) ;
493+ let program = Pubkey :: new_from_array ( [ 1 ; 32 ] ) ; // Consistent CUs when logging.
495494
496495 let programdata = get_program_data_address ( & program) ;
497496
@@ -529,6 +528,7 @@ fn programdata_success() {
529528 ] ,
530529 & [
531530 Check :: success ( ) ,
531+ Check :: compute_units ( 14_432 ) ,
532532 // Closed, but still owned by the loader.
533533 Check :: account ( & programdata)
534534 . data ( & [ 0 , 0 , 0 , 0 ] ) // Size of Uninitialized.
0 commit comments