This contract enable to deposit to the ETH2 Deposit Contract multiple times in a single transaction.
You can test the contract on both goerli testnet or in your local development environment.
- Clone
npm install
- In a terminal run
npx ganache-cli
- In another terminal run
npx truffle deploy
- Clone the repository
- Install Ganache and Truffle
- Run ganache and quick start an empty workspace
- Tun
truffle deploy
to compile & deploy, or justtruffle test
to compile, deploy and test automatically.
- Get some funds from the faucet
- Replace mnemonic in
./scripts/test_goerli.js
- Replace fake data with some real eth2 validator informations
- Check if the smart contract address is correct
- Run the script with
cd scripts && node test_goerli.js
Assertion libraries supported are chai assertion library and truffle-assertions. Tests are written with Mocha.
You can find test under tests
folder and run all the tests using truffle test
command
You can test code coverage by simply running npm run coverage
, a local blockchain at port 8545 will be automatically provided and shutdown after all the tests are done.
To deploy in production is reccomended to use Remix IDE, expected gas usage is around 492,831
.
Refer to https://github.com/crytic/solc-select
Refer to https://github.com/crytic/slither