Skip to content

feat(forge): invariant tests#849

Closed
brockelmore wants to merge 5 commits intomasterfrom
brock/invariant
Closed

feat(forge): invariant tests#849
brockelmore wants to merge 5 commits intomasterfrom
brock/invariant

Conversation

@brockelmore
Copy link
Member

@brockelmore brockelmore commented Mar 6, 2022

Adds invariant tests.

creates a strategy for selecting a contract from identified contracts, and a strategy for fuzzing the input params. If the call succeeds, check all the invariants in the contract (as defined by invariant prefix to a public function).

TODO:

  • multiple rounds of calls (currently only does 1 call)
  • function selector strategy currently never grabs index 0 it seems
  • update identified contracts after each call (instead of just after setup)
  • utilize the calldata strategy in fuzz_dict branch for state lifting
  • add state lifting in invariant fuzzes
  • add return data & input data into state lift dictionary

@onbjerg onbjerg added the T-feature Type: feature label Mar 7, 2022
@onbjerg onbjerg mentioned this pull request Mar 7, 2022
8 tasks
@onbjerg onbjerg mentioned this pull request Mar 18, 2022
18 tasks
@joshieDo joshieDo mentioned this pull request May 9, 2022
22 tasks
@gakonst
Copy link
Member

gakonst commented May 10, 2022

superseded by #1572

@gakonst gakonst closed this May 10, 2022
@gakonst gakonst deleted the brock/invariant branch May 10, 2022 23:04
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

T-feature Type: feature

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants