This project holds a suite of integration tests for the Ethereum JSON-RPC API built in Lotus with the Filecoin EVM runtime.
This repo is the test runner for all the project repo in the extern/
folder.
- Go through the Lotus installation guide to install the dependencies
- Install node dependencies by running
npm install
- cd
./node
and runmake node
- Run the node in
./bin/node
- echo -n DEPLOYER_PRIVATE_KEY=0x > .env
- openssl rand -hex 32 >> .env
- echo -n USER_1_PRIVATE_KEY=0x >> .env
- openssl rand -hex 32 >> .env
- Copy the .env file into ./extern/fevm-hardhat-kit/, ./extern/openzeppelin-contracts/, ./extern/fevm-uniswap-v3-core/
- ethers.js and web3.js (root folder)
- npm install
- npx hardhat --network itest test
- ./extern/fevm-hardhat-kit
- change the
DEPLOYER_PRIVATE_KEY
in .env toPRIVATE_KEY
- yarn
- npx hardhat --network itest deploy
- change the
- ./extern/openzeppelin-contracts
- npm install
- npx hardhat --network itest test
- ./extern/fevm-uniswap-v3-core
- yarn
- npx hardhat --network itest test
-
Wrong kind of exception received: FVM's backtrace message format is different from Ethereum's, so this repo bypasses checking the revert reason by removing the following code from
node_modules/@openzeppelin/test-helpers/src/expectRevert.js
:expect(actualError).to.equal(expectedError, 'Wrong kind of exception received');
Dual-licensed: MIT, Apache Software License v2, by way of the Permissive License Stack.