-
Notifications
You must be signed in to change notification settings - Fork 1.8k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
* fix: make ForkIds unique * fix return correct id
- Loading branch information
Showing
4 changed files
with
73 additions
and
33 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,19 @@ | ||
// SPDX-License-Identifier: MIT OR Apache-2.0 | ||
pragma solidity 0.8.18; | ||
|
||
import "ds-test/test.sol"; | ||
import "../cheats/Vm.sol"; | ||
|
||
// https://github.com/foundry-rs/foundry/issues/6759 | ||
contract Issue6759Test is DSTest { | ||
Vm constant vm = Vm(HEVM_ADDRESS); | ||
|
||
function testCreateMulti() public { | ||
uint256 fork1 = vm.createFork("rpcAlias", 10); | ||
uint256 fork2 = vm.createFork("rpcAlias", 10); | ||
uint256 fork3 = vm.createFork("rpcAlias", 10); | ||
assert(fork1 != fork2); | ||
assert(fork1 != fork3); | ||
assert(fork2 != fork3); | ||
} | ||
} |