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

Flaky contracts fuzz test #249

Open
karlb opened this issue Oct 4, 2024 · 0 comments
Open

Flaky contracts fuzz test #249

karlb opened this issue Oct 4, 2024 · 0 comments

Comments

@karlb
Copy link

karlb commented Oct 4, 2024

The latest optimism version contains fuzz tests that seem to pick up all contracts in the repo. That sometimes leads to fuzz test failures related to AddressSortedLinkedListWithMedian like https://app.circleci.com/pipelines/github/celo-org/optimism/1829/workflows/f2d42480-6c0f-40fe-9561-5a7bd2ab3932/jobs/32600. Obviously, I would like to get rid of the test failures.

Potential solutions:

  • Change AddressSortedLinkedListWithMedian to pass the tests (I don't know what the problem is, though)
  • Remove AddressSortedLinkedListWithMedian . But it is used in the SortedOracles which is used in the cUSD setup.
  • Skip it in tests. Maybe something like vm.assume(_addr != getAddress("AddressSortedLinkedListWithMedian"));?

Steps to reproduce: Run FOUNDRY_FUZZ_RUNS=1000000 forge test --match-test testFuzz_callWithMinGas_hasEnough_succeeds in packages/contracts-bedrock in the celo8 branch of celo-org/optimism .

Previous discussion: https://clabsco.slack.com/archives/CP5V8KF51/p1726577073321929

@martinvol:

Would focus on reliably disabling the tests

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant