summary refs log tree commit diff stats
path: root/tests/async/tasyncawait.nim
diff options
context:
space:
mode:
Diffstat (limited to 'tests/async/tasyncawait.nim')
-rw-r--r--tests/async/tasyncawait.nim4
1 files changed, 4 insertions, 0 deletions
diff --git a/tests/async/tasyncawait.nim b/tests/async/tasyncawait.nim
index 1e6cf3761..063c8317c 100644
--- a/tests/async/tasyncawait.nim
+++ b/tests/async/tasyncawait.nim
@@ -26,6 +26,10 @@ proc launchSwarm(port: Port) {.async.} =
 proc readMessages(client: AsyncFD) {.async.} =
   # wrapping the AsyncFd into a AsyncSocket object
   var sockObj = newAsyncSocket(client)
+  var (ipaddr, port) = sockObj.getPeerAddr()
+  doAssert ipaddr == "127.0.0.1"
+  (ipaddr, port) = sockObj.getLocalAddr()
+  doAssert ipaddr == "127.0.0.1"
   while true:
     var line = await recvLine(sockObj)
     if line == "":