[profile.default] src = 'contracts' out = 'out' libs = ['node_modules', 'lib'] test = 'test' cache_path = 'cache_forge' solc = "0.8.26" # 确保使用支持 cancun 的版本 evm_version = "cancun" via_ir = true optimizer = true ffi = true bytecode_hash = "none" cbor_metadata = false fs_permissions = [ { access = "read-write", path = ".forge-snapshots/" }, { access = "read", path = "./foundry-out" }, { access = "read", path = "./script/config" }, { access = "read", path = "./test/bin" }, { access = "read", path = "./test/pool-bin/bin" }, ] gas_limit = "300000000" remappings = [ 'ds-test/=lib/forge-std/lib/ds-test/src/', 'forge-gas-snapshot/=lib/forge-gas-snapshot/src/', 'forge-std/=lib/forge-std/src/', '@openzeppelin/=lib/openzeppelin-contracts/', 'solmate/=lib/solmate/', 'src/=contracts/' ] # added due to v1.0 foundry # ref: https://book.getfoundry.sh/guides/v1.0-migration#expect-revert-cheatcode-disabled-on-internal-calls-by-default allow_internal_expect_revert = true [fuzz] runs = 5 # change this for higher number of fuzz runs locally [profile.ci.fuzz] runs = 10000 [profile.ci.invariant] runs = 1000 # The number of calls to make in the invariant tests call_override = false # Override calls fail_on_revert = false # Fail the test if the contract reverts [profile.ci_main.fuzz] runs = 100000 [profile.ci_main.invariant] runs = 10000 # The number of calls to make in the invariant tests call_override = false # Override calls fail_on_revert = false # Fail the test if the contract reverts