Skip to content

Commit 6986dfa

Browse files
authored
Fix flaky testTime on Bahamut (#317)
1 parent 4ee99ed commit 6986dfa

File tree

1 file changed

+6
-0
lines changed

1 file changed

+6
-0
lines changed

irctest/server_tests/time.py

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -11,6 +11,12 @@ def testTime(self):
1111
self.connectClient("user")
1212

1313
time_before = math.floor(time.time())
14+
if self.controller.software_name == "Bahamut":
15+
# Bahamut's io_loop() sets NOW = time(NULL) *then* waits for events,
16+
# and reads NOW from the event handlers.
17+
# This means that its time can be off by as much as its read timeout.
18+
time_before -= 1
19+
1420
self.sendLine(1, "TIME")
1521

1622
msg = self.getMessage(1)

0 commit comments

Comments
 (0)