-
Notifications
You must be signed in to change notification settings - Fork 180
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
Add CosmOrc test for NFT mint, transfer, and instantiate gas usage. #84
base: main
Are you sure you want to change the base?
Conversation
bfdbe1d
to
5627cf5
Compare
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.
Awesome!
5627cf5
to
2229636
Compare
2229636
to
aaaaf91
Compare
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.
Looks great!
Just a minor comment.
Extremely useful, thanks Ekez |
This orc things looks cool. Is it ready for larger use? Can you link it here? CosmWasm/cw-plus#507 We had been discussing some way to benchmark gas better, but in the end it needs a chain, not just a local vm, to do this proper. |
Done. I think it's ready? |
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.
Really nice example of gas benchmark integration 👍 Gotta save link for later
e2e integration tests with gas profiling. | ||
|
||
`cd ci/integration_tests && cargo t` to run all tests. | ||
|
||
`cargo t fn_test_name` to run individual integration tests. |
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.
Also some CONFIG
variable needs to be set.
https://github.com/CosmWasm/cw-nfts/pull/84/files#diff-1d721ea28fc40ef113f3080306e4595d8176b794321429300530a386a0e305c6R83
and I don't see any mention about that (I might be blind though).
Co-authored-by: Jakub Bogucki <[email protected]>
2a26f4f
to
7e96526
Compare
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.
Should totally get this in after it's been updated.
This adds @de-husk's amazing cosmwasm orc library to this repository which allows us to run contract tests against a real local chan and measure gas usage while we're at it. It currently tests a simple instantiate, mint, and transfer flow and captures gas usage in
ci/integration-tests/gas_reports
.Here is an example gas report showing the gas usage of each operation:
Merging this will cause the associated GitHub action to make a comment on new changes describing how gas usage changed for its tests: