diff --git a/asyncdispatch2.nimble b/asyncdispatch2.nimble index cc5dcf3..6dd8171 100644 --- a/asyncdispatch2.nimble +++ b/asyncdispatch2.nimble @@ -38,6 +38,6 @@ task test, "Run all tests": exec "nim c -r tests/teststream" exec "nim c -r -d:release tests/teststream" - exec "nim c -r -d:useSysAssert -d:useGcAssert tests/teststream2" - exec "nim c -r tests/teststream2" - exec "nim c -r -d:release tests/teststream2" + exec "nim c -r -d:useSysAssert -d:useGcAssert tests/testserver" + exec "nim c -r tests/testserver" + exec "nim c -r -d:release tests/testserver" diff --git a/tests/testdatagram.nim b/tests/testdatagram.nim index a38b8e6..ed91d73 100644 --- a/tests/testdatagram.nim +++ b/tests/testdatagram.nim @@ -274,7 +274,6 @@ proc test4(): Future[int] {.async.} = server.close() when isMainModule: - echo waitFor(test4()) const m1 = "Unbounded test (" & $TestsCount & " messages)" m2 = "Bounded test (" & $TestsCount & " messages)" diff --git a/tests/teststream2.nim b/tests/testserver.nim similarity index 96% rename from tests/teststream2.nim rename to tests/testserver.nim index 2ef1cba..c6fe2b7 100644 --- a/tests/teststream2.nim +++ b/tests/testserver.nim @@ -48,7 +48,7 @@ proc swarmWorker1(address: TransportAddress): Future[int] {.async.} = proc test1(): Future[int] {.async.} = var ta = strAddress("127.0.0.1:31354") - var server = createStreamServer(ta, {ReuseAddr}, serveClient1) + var server = createStreamServer(ta, serveClient1, {ReuseAddr}) server.start() result = await swarmWorker1(ta) server.stop()