nim-dagger/tests/codex/testsystemclock.nim
Eric 61ec4275c8
Revert "remove call to waitFor from clock.now and make it async (#691)" (#707)
This reverts commit 591be9446a5cee1ce559c87e496fa4d7dab92924.
2024-02-16 22:12:16 +00:00

15 lines
279 B
Nim

import std/times
import std/unittest
import codex/systemclock
import ./helpers
checksuite "SystemClock":
test "Should get now":
let clock = SystemClock.new()
let expectedNow = times.now().utc
let now = clock.now()
check now == expectedNow.toTime().toUnix()