Skip to content

Commit 0a26e6d

Browse files
authored
Merge pull request #610 from DaniPopes/update-vm
feat(Vm): add new cheatcodes
2 parents 7bd2d22 + a652c65 commit 0a26e6d

File tree

2 files changed

+70
-13
lines changed

2 files changed

+70
-13
lines changed

src/Vm.sol

Lines changed: 61 additions & 7 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

test/Vm.t.sol

Lines changed: 9 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -4,12 +4,15 @@ pragma solidity >=0.8.0 <0.9.0;
44
import {Test} from "../src/Test.sol";
55
import {Vm, VmSafe} from "../src/Vm.sol";
66

7+
// These tests ensure that functions are never accidentally removed from a Vm interface, or
8+
// inadvertently moved between Vm and VmSafe. These tests must be updated each time a function is
9+
// added to or removed from Vm or VmSafe.
710
contract VmTest is Test {
8-
// This test ensures that functions are never accidentally removed from a Vm interface, or
9-
// inadvertently moved between Vm and VmSafe. This test must be updated each time a function is
10-
// added to or removed from Vm or VmSafe.
11-
function test_interfaceId() public pure {
12-
assertEq(type(VmSafe).interfaceId, bytes4(0x74d42398), "VmSafe");
13-
assertEq(type(Vm).interfaceId, bytes4(0xaf15a283), "Vm");
11+
function test_VmInterfaceId() public pure {
12+
assertEq(type(Vm).interfaceId, bytes4(0xa561dbe8), "Vm");
13+
}
14+
15+
function test_VmSafeInterfaceId() public pure {
16+
assertEq(type(VmSafe).interfaceId, bytes4(0x681d10d4), "VmSafe");
1417
}
1518
}

0 commit comments

Comments
 (0)