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

test: add tx priority checks to e2e tests #2184

Merged
merged 23 commits into from
May 16, 2024
Merged

Conversation

skosito
Copy link
Contributor

@skosito skosito commented May 14, 2024

Description

Add function to monitor blocks while e2e tests are executed, and at the end of execution, n some block system transactions are not above ethermint txs, it should fail. Initially wanted to do this only for performance tests, but this seems more complete and better because one monitoring is needed per execution, not per test - open to discussion.

Monitor function is not super clean, but it is based on information in txs results.

These txs are on top because they have highest priority in mempool. If this is executed on develop before priority mempool PR was merged, it would fail, because txs were included in FIFO order.

Closes: #2182

Type of change

Test addition.

How Has This Been Tested?

Please describe the tests that you ran to verify your changes. Include instructions and any relevant details so others can reproduce.

  • Tested CCTX in localnet
  • Tested in development environment
  • Go unit tests
  • Go integration tests
  • Tested via GitHub Actions

Checklist:

  • I have added unit tests that prove my fix feature works

Copy link
Member

@lumtis lumtis left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

If we didn't yet, would be great if we could (at least manually)

  • Toggle off the application mempool
  • Checking the test no longer pass

cmd/zetae2e/local/utils.go Outdated Show resolved Hide resolved
cmd/zetae2e/local/utils.go Outdated Show resolved Hide resolved
cmd/zetae2e/local/utils.go Outdated Show resolved Hide resolved
cmd/zetae2e/local/utils.go Outdated Show resolved Hide resolved
cmd/zetae2e/local/utils.go Outdated Show resolved Hide resolved
cmd/zetae2e/local/utils.go Outdated Show resolved Hide resolved
@lumtis lumtis linked an issue May 15, 2024 that may be closed by this pull request
@skosito
Copy link
Contributor Author

skosito commented May 15, 2024

@lumtis thanks for review, ready for 2nd pass

when NoOpMempool is used instead (which is previous version), tests fail on priority checks

this issue #2180 is not closed with this PR, i fixed it in previous and it is already merged, but lets open issue to update gosec to latest version, or rename this one from fix to update

@lumtis lumtis removed a link to an issue May 15, 2024
Copy link
Member

@lumtis lumtis left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM - minor comments

cmd/zetae2e/local/monitor_priority_txs.go Outdated Show resolved Hide resolved
cmd/zetae2e/local/monitor_priority_txs.go Show resolved Hide resolved
@skosito skosito requested a review from ws4charlie May 16, 2024 23:17
@skosito skosito merged commit adcb33c into develop May 16, 2024
21 checks passed
@skosito skosito deleted the custom-mempool-stress-tests branch May 16, 2024 23:44
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Include priority mempool checks in e2e/performance tests
3 participants