-
Notifications
You must be signed in to change notification settings - Fork 5k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
transaction integration tests #6071
Conversation
@@ -220,15 +218,6 @@ export async function defaultTransactionBuilder<ReturnType = Transaction>(option | |||
populatedTransaction.accessList = []; | |||
} | |||
|
|||
populatedTransaction = { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
fix: #6063
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
gas price is already assigned in sendTransaction and at this place its called again
Deploying with Cloudflare Pages
|
Bundle StatsHey there, this message comes from a github action that helps you and reviewers to understand how these changes affect the size of this project's bundle. As this PR is updated, I'll keep you updated on how the bundle size is impacted. Total
View detailed bundle breakdownAdded No assets were added Removed No assets were removed Bigger No assets were bigger Smaller No assets were smaller Unchanged
|
This PR is blocked due to bug : #6065 once second auto gas filling function call is not called for sendTransaction, in CI many tests are not passing : |
Codecov Report
Additional details and impacted files@@ Coverage Diff @@
## 4.x #6071 +/- ##
==========================================
- Coverage 87.41% 87.40% -0.01%
==========================================
Files 199 199
Lines 7614 7616 +2
Branches 2065 2067 +2
==========================================
+ Hits 6656 6657 +1
- Misses 958 959 +1
Flags with carried forward coverage won't be shown. Click here to find out more.
|
@@ -77,8 +77,12 @@ describe('web3.accounts', () => { | |||
}), | |||
).resolves.toBeDefined(); | |||
|
|||
const txWithGas = { | |||
...tx, | |||
gasPrice: '0x271000', |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
added gasPrice
explicitly in tests of this file, because now signTransaction
will not fill gas price and validation fails if no gasprice or gas0x2 params are provided .
}); | ||
}; | ||
|
||
return web3.eth.sendTransaction(txObj, undefined, { checkRevertBeforeSending: false }); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
use internal signing, as sendTransaction auto fills gas price if not provided,
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Great job!
I think we need to mention in the Added
section at CHANGELOG.md
that the fillGasPrice
parameter has been added to transactionBuilder
.
Description
#6013
Type of change
Checklist:
npm run lint
with success and extended the tests and types if necessary.npm run test:unit
with success.npm run test:coverage
and my test cases cover all the lines and branches of the added code.npm run build
and testeddist/web3.min.js
in a browser.CHANGELOG.md
file in the root folder.