diff options
author | Dmitry Polienko <dmitry@eldis.ru> | 2016-09-13 02:00:37 -0700 |
---|---|---|
committer | Dmitry Polienko <dmitry@eldis.ru> | 2016-09-13 02:00:37 -0700 |
commit | a2a5985a2dd47ed591b6a6617650a530ce3cd23d (patch) | |
tree | b6de3f55291e28ea1f579777e9b7b208e18b9d93 /tests/async/tasyncsend4757.nim | |
parent | d810b4515eb3f9b04a4d2b95b9951bc967d354ef (diff) | |
download | Nim-a2a5985a2dd47ed591b6a6617650a530ce3cd23d.tar.gz |
Add test for issue #4757
Diffstat (limited to 'tests/async/tasyncsend4757.nim')
-rw-r--r-- | tests/async/tasyncsend4757.nim | 16 |
1 files changed, 16 insertions, 0 deletions
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) |