- Added a `close()` method
- Call `close()` on the `BClient` at the end of the unit test
This commit is contained in:
Tristan B. Velloza Kildaire 2023-04-30 19:07:36 +02:00
parent d9f34fbac4
commit afab414d01
1 changed files with 10 additions and 0 deletions

View File

@ -145,6 +145,14 @@ public class BClient
}
}
/**
* Closes the client
*/
public void close()
{
/* Close the underlying stream */
stream.close();
}
}
version(unittest)
@ -206,4 +214,6 @@ unittest
assert(receivedMessage == "ABBA");
writeln(receivedMessage);
writeln(cast(string)receivedMessage);
bClient.close();
}