Formatting

This commit is contained in:
Mark Spanbroek 2020-12-02 16:06:04 +01:00 committed by markspanbroek
parent 124ac8152f
commit db54516c0f
2 changed files with 5 additions and 4 deletions

View File

@ -19,7 +19,8 @@ proc hasConnection(listener: Listener, id: ConnectionId): bool =
proc getConnection(listener: Listener, id: ConnectionId): Connection =
listener.connections[id]
proc addConnection(listener: Listener, connection: Connection, firstId: ConnectionId) {.async.} =
proc addConnection(listener: Listener, connection: Connection,
firstId: ConnectionId) {.async.} =
connection.quic.onNewId = proc (newId: ConnectionId) =
listener.connections[newId] = connection
for id in connection.quic.ids & firstId:

View File

@ -20,7 +20,7 @@ suite "listener":
check connection != nil
done()
listener.udp = newDatagramTransport(onReceive, local=address)
listener.udp = newDatagramTransport(onReceive, local = address)
await exampleQuicDatagram().sendTo(address)
asynctest "re-uses connection for known connection id", done:
@ -36,7 +36,7 @@ suite "listener":
await connection.close()
done()
listener.udp = newDatagramTransport(onReceive, local=address)
listener.udp = newDatagramTransport(onReceive, local = address)
let datagram = exampleQuicDatagram()
await datagram.sendTo(address)
await datagram.sendTo(address)
@ -54,6 +54,6 @@ suite "listener":
await connection.close()
done()
listener.udp = newDatagramTransport(onReceive, local=address)
listener.udp = newDatagramTransport(onReceive, local = address)
await exampleQuicDatagram().sendTo(address)
await exampleQuicDatagram().sendTo(address)