From a2a5985a2dd47ed591b6a6617650a530ce3cd23d Mon Sep 17 00:00:00 2001 From: Dmitry Polienko Date: Tue, 13 Sep 2016 02:00:37 -0700 Subject: Add test for issue #4757 --- tests/async/tasyncsend4757.nim | 16 ++++++++++++++++ 1 file changed, 16 insertions(+) create mode 100644 tests/async/tasyncsend4757.nim (limited to 'tests') diff --git a/tests/async/tasyncsend4757.nim b/tests/async/tasyncsend4757.nim new file mode 100644 index 000000000..2ae4a6151 --- /dev/null +++ b/tests/async/tasyncsend4757.nim @@ -0,0 +1,16 @@ +discard """ + file: "tasyncsend4754.nim" + output: "Finished" +""" + +import asyncdispatch + +proc f(): Future[void] {.async.} = + let s = newAsyncNativeSocket() + await s.connect("example.com", 80.Port) + await s.send("123") + echo "Finished" + +asyncCheck f() + +poll(1000) -- cgit 1.4.1-2-gfad0