Skip to content

rohitgoyal/mesh_finance_core

 
 

Repository files navigation

Introduction

This is the official repo of Mesh Finance.

Installation and Setup

  1. Install Brownie & Ganache-CLI.

  2. Sign up for Infura and generate an API key. Store it in the WEB3_INFURA_PROJECT_ID environment variable.

export WEB3_INFURA_PROJECT_ID=ProjectID
  1. Sign up for Etherscan and generate an API key. This is required for fetching source codes of the mainnet contracts like DAI, yvaults etc. Store the API key in the ETHERSCAN_TOKEN environment variable.
export ETHERSCAN_TOKEN=ApiToken
  1. Compile the project. This will also install the dependencies from the config file.
brownie compile

Testing

Current scope of testing is funds contracts. For specific strategies, testing needs to be done manually for now.

To run the tests:

brownie test

This will run all the tests in the test folder. By default, this is configured to run on the mainnet-fork.

For test coverage, use coverage flag.

brownie test --coverage

You can run the tests on local ganache blockchain using development flag.

brownie test --network development

Check Brownie documentation for testing and Brownie documentation for networks.

Security and linting

We are using solhint and prettier for base secutiry checks and linting the code. It can be used in 2 steps. First fixes all the linting issues. Second checks for any vulnerabilies including formatting.

yarn lint
yarn solhint

About

DeFi Asset Management

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages

  • Solidity 52.2%
  • Python 47.7%
  • JavaScript 0.1%