We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 4dc5078 commit cd7d53cCopy full SHA for cd7d53c
prt/contracts/test/Clock.t.sol
@@ -16,8 +16,15 @@ import "src/tournament/libs/Clock.sol";
16
17
pragma solidity ^0.8.0;
18
19
+library ExternalClock {
20
+ function advanceClockExternal(Clock.State storage state) external {
21
+ Clock.advanceClock(state);
22
+ }
23
+}
24
+
25
contract ClockTest is Test {
26
using Clock for Clock.State;
27
+ using ExternalClock for Clock.State;
28
using Time for Time.Instant;
29
30
Clock.State clock1;
@@ -69,6 +76,6 @@ contract ClockTest is Test {
69
76
assertTrue(!clock1.hasTimeLeft(), "clock1 should run out of time");
70
77
71
78
vm.expectRevert("can't advance clock with no time left");
72
- clock1.advanceClock();
79
+ clock1.advanceClockExternal();
73
80
}
74
81
0 commit comments