File tree Expand file tree Collapse file tree 2 files changed +4
-7
lines changed
Tests/web3swiftTests/localTests Expand file tree Collapse file tree 2 files changed +4
-7
lines changed Original file line number Diff line number Diff line change @@ -654,8 +654,7 @@ class web3swiftTransactionsTests: XCTestCase {
654
654
655
655
let details = try web3. eth. getTransactionDetails ( txHash)
656
656
print ( details)
657
- let options = details. transaction. getOptions ( )
658
- let txnGasLimit = options. resolveGasLimit ( 0 )
657
+ let txnGasLimit = details. transaction. gasLimit
659
658
XCTAssert ( txnGasLimit == BigUInt ( 78423 ) )
660
659
} catch Web3Error . nodeError( let descr) {
661
660
guard descr == " insufficient funds for gas * price + value " else { return XCTFail ( ) }
Original file line number Diff line number Diff line change @@ -47,8 +47,7 @@ class web3swiftUserCases: XCTestCase {
47
47
let gasEstimate = try writeTX. estimateGasPromise ( ) . wait ( )
48
48
writeTX. transactionOptions. gasLimit = . manual( gasEstimate + 1234 )
49
49
let assembled = try writeTX. assemblePromise ( ) . wait ( )
50
- let options = assembled. getOptions ( )
51
- let txnGasLimit = options. resolveGasLimit ( 0 )
50
+ let txnGasLimit = assembled. gasLimit
52
51
XCTAssert ( txnGasLimit == gasEstimate + 1234 )
53
52
}
54
53
@@ -63,9 +62,8 @@ class web3swiftUserCases: XCTestCase {
63
62
let gasEstimate = try writeTX. estimateGasPromise ( ) . wait ( )
64
63
writeTX. transactionOptions. gasLimit = . manual( gasEstimate + 1234 )
65
64
let assembled = try writeTX. assemblePromise ( ) . wait ( )
66
- let options = assembled. getOptions ( )
67
- let txnGasLimit = options. resolveGasLimit ( 0 )
68
- let txnGasPrice = options. resolveGasPrice ( 0 )
65
+ let txnGasLimit = assembled. gasLimit
66
+ let txnGasPrice = assembled. gasPrice
69
67
70
68
XCTAssert ( txnGasLimit == gasEstimate + 1234 )
71
69
XCTAssert ( txnGasPrice == gasPrice * 2 )
You can’t perform that action at this time.
0 commit comments