2023-12-21 09:01:45 +00:00
|
|
|
import pkg/asynctest/chronos/unittest
|
2023-12-20 14:11:32 +00:00
|
|
|
|
2023-12-21 09:01:45 +00:00
|
|
|
include ../common/testbody
|
|
|
|
include ../common/testfail
|
2024-01-10 12:01:34 +00:00
|
|
|
|
|
|
|
import std/times
|
|
|
|
|
|
|
|
suite "eventually and std/times":
|
|
|
|
|
|
|
|
test "compiles when both chronos and std/times are imported":
|
|
|
|
check eventually true
|
2024-01-11 19:54:33 +00:00
|
|
|
|
|
|
|
test "compiles when the expression handed to eventually can raise Exception":
|
|
|
|
proc aProc(): bool {.raises: [Exception].} = raise newException(
|
|
|
|
Exception, "an exception")
|
|
|
|
check:
|
|
|
|
compiles:
|
|
|
|
discard eventually aProc()
|