Skip to content

Commit

Permalink
test: fix gas cost estimation
Browse files Browse the repository at this point in the history
  • Loading branch information
iqdecay committed Jun 21, 2023
1 parent aeec4b4 commit ea17820
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 5 deletions.
4 changes: 2 additions & 2 deletions examples/contracts/src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -107,7 +107,7 @@ mod tests {
.await?;
// ANCHOR_END: contract_call_cost_estimation

assert_eq!(transaction_cost.gas_used, 625);
assert_eq!(transaction_cost.gas_used, 498);

Ok(())
}
Expand Down Expand Up @@ -631,7 +631,7 @@ mod tests {
.await?;
// ANCHOR_END: multi_call_cost_estimation

assert_eq!(transaction_cost.gas_used, 1021);
assert_eq!(transaction_cost.gas_used, 783);

Ok(())
}
Expand Down
6 changes: 3 additions & 3 deletions packages/fuels/tests/contracts.rs
Original file line number Diff line number Diff line change
Expand Up @@ -280,9 +280,9 @@ async fn test_contract_call_fee_estimation() -> Result<()> {
let tolerance = 0.2;

let expected_min_gas_price = 0; // This is the default min_gas_price from the ConsensusParameters
let expected_gas_used = 750;
let expected_metered_bytes_size = 720;
let expected_total_fee = 368;
let expected_gas_used = 597;
let expected_metered_bytes_size = 728;
let expected_total_fee = 372;

let estimated_transaction_cost = contract_instance
.methods()
Expand Down

0 comments on commit ea17820

Please sign in to comment.