forked from allo-protocol/allo-v2
-
Notifications
You must be signed in to change notification settings - Fork 3
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #58 from allo-protocol/test/summary-md
chore: test doc + echidna retrocompat
- Loading branch information
Showing
4 changed files
with
36 additions
and
16 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,8 +1,18 @@ | ||
# Tests summary. | ||
|
||
## Unit Tests | ||
Written using [Forge Foundry](https://getfoundry.sh/), [Smock](https://github.com/defi-wonderland/smock-foundry) and [Bulloak](https://www.bulloak.dev/), | ||
they cover every contracts of this repository. | ||
|
||
To run them, after installing all dependencies, generate the mocks using `[your package manager] smock` (eg `yarn mock`) | ||
then run the tests using `[your package manager] test:unit` (eg `yarn test`). | ||
|
||
Medusa: | ||
- No agent, substitued by profile owner or member | ||
## Integration Tests | ||
We cover every user story of the strategies. | ||
To run them, after installing depedencies, define both Optimism and Mainnet RPC URL (eg `export MAINNET_RPC_URL=https://etc`), then use `[your package manager] test:integration` (eg `yarn test:integration`). | ||
|
||
|
||
TODO: use trusted forwarder | ||
## Invariant Tests | ||
We assess how 8 invariants are holding against Medusa and Echidna fuzzer (see the PROPERTIES.md file | ||
for the complete list). To run both campaigns, use the following commands: | ||
- `medusa fuzz .` (this is our default tool, configuration is included in this repo) | ||
- `echidna --contract FuzzTest --test-mode assertion test/invariant/fuzz/FuzzTest.t.sol` |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters