-
Hi Everyone, I am currently completing the testing in the upgradeable smart contract portion of the Advanced foundry course. I am unsure why but when I used function testUpgrade() public {
uint8 expectedVersion = 2;
uint256 expectedNumber = 3;
BoxV2 boxV2 = new BoxV2();
upgrader.upgradeBox(proxy, address(boxV2));
uint8 currentVersion = BoxV2(proxy).getVersion();
assertEq(currentVersion, expectedVersion);
BoxV2(proxy).setNumber(3);
assertEq(BoxV2(proxy).getNumber(), expectedNumber);
} Link to my repo: https://github.com/MGM103/upgradeability-solidity Appreciate the explanation in advance! |
Beta Was this translation helpful? Give feedback.
Answered by
EngrPips
Apr 28, 2024
Replies: 1 comment 4 replies
-
Hello, @MGM103. That seems weird, but I suggest you run |
Beta Was this translation helpful? Give feedback.
4 replies
Answer selected by
MGM103
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Hello, @MGM103. That seems weird, but I suggest you run
foundry
and retry. Let us know if it works after runningfoundryUp