Skip to content

Commit

Permalink
fix: hardfork
Browse files Browse the repository at this point in the history
  • Loading branch information
antazoey committed Jul 20, 2023
1 parent dd5b0f3 commit 112d26d
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 1 deletion.
2 changes: 1 addition & 1 deletion ape_hardhat/provider.py
Original file line number Diff line number Diff line change
Expand Up @@ -53,9 +53,9 @@
HARDHAT_CONFIG = """
// See https://hardhat.org/config/ for config options.
module.exports = {{
hardfork: "{hard_fork}",
networks: {{
hardhat: {{
hardfork: "{hard_fork}",
// Base fee of 0 allows use of 0 gas price when testing
initialBaseFeePerGas: 0,
accounts: {{
Expand Down
7 changes: 7 additions & 0 deletions tests/test_provider.py
Original file line number Diff line number Diff line change
Expand Up @@ -329,3 +329,10 @@ def test_remote_host(temp_config, networks, no_hardhat_bin, project):
):
with networks.ethereum.local.use_provider("hardhat"):
pass


def test_hardfork(temp_config, networks):
data = {"hardhat": {"hardfork": "london"}}
with temp_config(data):
with networks.ethereum.local.use_provider("hardhat") as provider:
assert provider.config.hardfork == "londond"

0 comments on commit 112d26d

Please sign in to comment.