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

Add native Clarity fuzzing for sBTC contracts #882

Open
wants to merge 9 commits into
base: main
Choose a base branch
from

Conversation

moodmosaic
Copy link
Member

This adds native, Clarity-based fuzzing for the sBTC contracts, inspired by prior work in stacks-core#4550 and stacks-core#4842.

The approach is similar to Echidna and Foundry but uses Rendezvous, a forthcoming tool for Clarity fuzzing. This PR will move out of draft once Rendezvous is publicly available and all sBTC contracts are covered.

moodmosaic and others added 2 commits November 18, 2024 16:17
- Create `.invariants.clar` files for stateful, invariant fuzzing.
- Create `.tests.clar` files for property-based testing.
- Add placeholder comments to each file indicating their purpose.
(cherry picked from commit a61a426)
(cherry picked from commit 7686ffd)
This commit adds four invariants that check general truths in the registry
contract regarding:
- current-signature-threshold variable
- current-signer-principal variable
- current-aggregate-pubkey variable
- multi-sig-address map
This commit unifies the invariants and the property-based tests for each
contract in a single `.tests` Clarity file.
@moodmosaic
Copy link
Member Author

Taking the PR out of draft state now that rendezvous has been open-sourced (see hirosystems/clarinet#398 (comment)).

@moodmosaic moodmosaic marked this pull request as ready for review December 27, 2024 14:09
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

Successfully merging this pull request may close these issues.

2 participants