From 58b5b5ea59bacd181be6f402c6f85f561794df67 Mon Sep 17 00:00:00 2001 From: ichristwin Date: Fri, 20 Oct 2023 23:54:20 +0100 Subject: [PATCH] finished setup fort github workflow --- foundry.toml | 6 +++++- test/Solaxy.invariant.t.sol | 3 ++- test/Solaxy.t.sol | 3 ++- 3 files changed, 9 insertions(+), 3 deletions(-) diff --git a/foundry.toml b/foundry.toml index 4a35b34..aec0a86 100644 --- a/foundry.toml +++ b/foundry.toml @@ -2,19 +2,23 @@ src = "src" out = "out" libs = ["lib"] -solc-version = "0.8.19" optimizer = true optimizer-runs = 1000 +solc-version = "0.8.19" remappings = [ "@prb/math@4.0.1/=lib/prb-math/", "@openzeppelin/contracts@4.9.3/=lib/openzeppelin-contracts/contracts/" ] +[rpc_endpoints] +iotex-mainnet = "https://babel-api.mainnet.iotex.io/" + [fuzz] seed = 0x544D [invariant] +runs = 256 # See more config options https://github.com/foundry-rs/foundry/blob/master/crates/config/README.md#all-options diff --git a/test/Solaxy.invariant.t.sol b/test/Solaxy.invariant.t.sol index ca6425c..de73f26 100644 --- a/test/Solaxy.invariant.t.sol +++ b/test/Solaxy.invariant.t.sol @@ -58,7 +58,8 @@ contract SolaxyInvarantTest is Test { address public handlerAddress; function setUp() public { - vm.createSelectFork("https://babel-api.mainnet.iotex.io/", 24_838_201); + string memory url = vm.rpcUrl("iotex-mainnet"); + vm.createSelectFork(url, 24_838_201); slx = new Solaxy(address(99)); slxAddress = address(slx); diff --git a/test/Solaxy.t.sol b/test/Solaxy.t.sol index 7bf7e73..e04a6b1 100644 --- a/test/Solaxy.t.sol +++ b/test/Solaxy.t.sol @@ -20,7 +20,8 @@ contract SolaxyTest is Test { uint256 public constant oneMillionDaiBalance = 1e6 * 1e18; function setUp() public { - vm.createSelectFork("https://babel-api.mainnet.iotex.io/", 24_838_201); + string memory url = vm.rpcUrl("iotex-mainnet"); + vm.createSelectFork(url, 24_838_201); here = address(this); slx = new Solaxy(address(99));