File tree Expand file tree Collapse file tree 5 files changed +17
-2
lines changed Expand file tree Collapse file tree 5 files changed +17
-2
lines changed Original file line number Diff line number Diff line change @@ -404,6 +404,7 @@ mod tests {
404
404
// fake a reply and ensure this works
405
405
let response = Reply {
406
406
id,
407
+ gas_used : 1234567 ,
407
408
result : SubMsgResult :: Ok ( SubMsgResponse {
408
409
events : fake_events ( & account) ,
409
410
data : None ,
@@ -481,6 +482,7 @@ mod tests {
481
482
// fake a reply and ensure this works
482
483
let response = Reply {
483
484
id,
485
+ gas_used : 1234567 ,
484
486
result : SubMsgResult :: Ok ( SubMsgResponse {
485
487
events : fake_events ( REFLECT_ADDR ) ,
486
488
data : None ,
Original file line number Diff line number Diff line change @@ -95,6 +95,7 @@ fn connect(
95
95
// fake a reply and ensure this works
96
96
let response = Reply {
97
97
id,
98
+ gas_used : 1234567 ,
98
99
result : SubMsgResult :: Ok ( SubMsgResponse {
99
100
events : fake_events ( & account) ,
100
101
data : None ,
@@ -173,6 +174,7 @@ fn proper_handshake_flow() {
173
174
// we get the callback from reflect
174
175
let response = Reply {
175
176
id,
177
+ gas_used : 1234567 ,
176
178
result : SubMsgResult :: Ok ( SubMsgResponse {
177
179
events : fake_events ( REFLECT_ADDR ) ,
178
180
data : None ,
Original file line number Diff line number Diff line change @@ -434,11 +434,16 @@ mod tests {
434
434
let id = 123u64 ;
435
435
let data = Binary :: from ( b"foobar" ) ;
436
436
let events = vec ! [ Event :: new( "message" ) . add_attribute( "signer" , "caller-addr" ) ] ;
437
+ let gas_used = 1234567u64 ;
437
438
let result = SubMsgResult :: Ok ( SubMsgResponse {
438
439
events : events. clone ( ) ,
439
440
data : Some ( data. clone ( ) ) ,
440
441
} ) ;
441
- let subcall = Reply { id, result } ;
442
+ let subcall = Reply {
443
+ id,
444
+ gas_used,
445
+ result,
446
+ } ;
442
447
let res = reply ( deps. as_mut ( ) , mock_env ( ) , subcall) . unwrap ( ) ;
443
448
assert_eq ! ( 0 , res. messages. len( ) ) ;
444
449
Original file line number Diff line number Diff line change @@ -268,11 +268,16 @@ fn reply_and_query() {
268
268
let id = 123u64 ;
269
269
let data = Binary :: from ( b"foobar" ) ;
270
270
let events = vec ! [ Event :: new( "message" ) . add_attribute( "signer" , "caller-addr" ) ] ;
271
+ let gas_used = 1234567u64 ;
271
272
let result = SubMsgResult :: Ok ( SubMsgResponse {
272
273
events : events. clone ( ) ,
273
274
data : Some ( data. clone ( ) ) ,
274
275
} ) ;
275
- let subcall = Reply { id, result } ;
276
+ let subcall = Reply {
277
+ id,
278
+ gas_used,
279
+ result,
280
+ } ;
276
281
let res: Response = reply ( & mut deps, mock_env ( ) , subcall) . unwrap ( ) ;
277
282
assert_eq ! ( 0 , res. messages. len( ) ) ;
278
283
Original file line number Diff line number Diff line change @@ -900,6 +900,7 @@ mod tests {
900
900
// which creates a reflect account. here we get the callback
901
901
let response = Reply {
902
902
id,
903
+ gas_used : 1234567 ,
903
904
result : SubMsgResult :: Ok ( SubMsgResponse {
904
905
events : vec ! [ event] ,
905
906
data : None ,
You can’t perform that action at this time.
0 commit comments