CoapClient (unit test)

- Re-enabled previously disabled normal non-timeout-based test
This commit is contained in:
Tristan B. Velloza Kildaire 2023-09-25 14:49:56 +02:00
parent ecd85e195e
commit 1d4cce19ca
1 changed files with 10 additions and 10 deletions

View File

@ -302,21 +302,21 @@ version(unittest)
*/
unittest
{
// CoapClient client = new CoapClient("coap.me", 5683);
CoapClient client = new CoapClient("coap.me", 5683);
// CoapRequestFuture future = client.newRequestBuilder()
// .payload(cast(ubyte[])"Hello this is Tristan!")
// .token([69])
// .post();
CoapRequestFuture future = client.newRequestBuilder()
.payload(cast(ubyte[])"Hello this is Tristan!")
.token([69])
.post();
// writeln("Future start");
// CoapPacket response = future.get();
// writeln("Future done");
// writeln("Got response: ", response);
writeln("Future start");
CoapPacket response = future.get();
writeln("Future done");
writeln("Got response: ", response);
// client.close();
client.close();
}
version(unittest)