Skip to content
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

Automated gas consumption test: token swap #314

Open
taokayan opened this issue Oct 24, 2024 · 0 comments
Open

Automated gas consumption test: token swap #314

taokayan opened this issue Oct 24, 2024 · 0 comments
Assignees

Comments

@taokayan
Copy link
Contributor

taokayan commented Oct 24, 2024

Depends on #305

Develop automated tests to verify the gas consumption are same across the following executors (including using the latest gas algorithm with custom gas parameters):

  • executor in the evm-runtime contract
  • executor in evm-node
  • executor used in gas estimation via rpc
  • executor in transaction trace
  • executor in vmTrace

for the following transactions:

  • swap contract deployment
  • swap contract initialization
  • 1st transfer tokens to swap contract (init funds for the swap pool)
  • 2nd transfer tokens to swap contract (add funds to existing pool)
  • token swap to new account (account that does not have ERC20 token balance)
  • token swap to existing account (account that has ERC20 token balance)

use eth-brownie to help us with the setup of the contracts (uniswap pools, nft, etc) and also with the interaction with the EVM since all our integration tests are using python already.

also look into hardhat.config used in eos-evm-node and also scripts.

measure the executor in the evm-runtime contract by using the balance difference and the gas price

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
Status: Todo
Development

No branches or pull requests

2 participants