storming0x / serpentor

A set of smart contracts tools for governance written in vyper
GNU Affero General Public License v3.0
53 stars 5 forks source link

Serpentor

Forge tests Python tests License: AGPL v3

A set of smart contracts tools for governance written in vyper

Contracts

Requirements

The test environment requires that the vyper compiler command can be accessed from your path

vyper install instructions

As an alternative you can also install vvm

and run

vvm install 0.3.6

Setup

This project uses foundry and apeworx to combine both unit test, fuzz tests with integration tests in python.

Install ape framework.

See ape quickstart guide

Install foundry

Install JS dependencies

npm install

Build

forge build

Run tests

forge test

Run tests with traces

forge test -vvv

Recommendation: for faster test times install vvm-rs. This will add a caching layer to the vyper compiler that improves test times with forge. E.g 32s-> 52ms in local benchmarks

Build with ape

ape compile

Run python tests

ape test

Disclaimer

This is experimental software and is provided on an "as is" and "as available" basis without any warranties.

While the first release has been audited, these contracts have not been widely used in production.

Use at your own risk.

Acknowledgements