mirror of
https://github.com/status-im/asynctest.git
synced 2025-02-23 01:58:18 +00:00
17 lines
314 B
Nim
17 lines
314 B
Nim
|
import std/unittest
|
||
|
import std/asyncdispatch
|
||
|
import pkg/asynctest
|
||
|
|
||
|
suite "async tests":
|
||
|
|
||
|
proc asyncproc {.async.} = discard
|
||
|
|
||
|
asyncsetup: # allows await in setup
|
||
|
await asyncproc()
|
||
|
|
||
|
asyncteardown: # allows await in teardown
|
||
|
await asyncproc()
|
||
|
|
||
|
asynctest "allows await in tests":
|
||
|
await asyncproc()
|