diff --git a/source/birchwood/client.d b/source/birchwood/client.d index fd02879..01c2d45 100644 --- a/source/birchwood/client.d +++ b/source/birchwood/client.d @@ -325,6 +325,9 @@ public class Client : Thread { //TODO: Add check for # + /* Append on a trailing `,` */ + channelLine ~= ","; + for(ulong i = 1; i < channels.length; i++) { string currentChannel = channels[i]; @@ -1184,6 +1187,9 @@ public class Client : Thread client.joinChannel("#birchwood"); // TODO: Add a joinChannels(string[]) client.joinChannel("#birchwood2"); + client.joinChannel("#birchwoodLeave1"); + client.joinChannel("#birchwoodLeave2"); + client.joinChannel("#birchwoodLeave3"); Thread.sleep(dur!("seconds")(2)); client.command(new Message("", "NAMES", "")); @@ -1222,6 +1228,23 @@ public class Client : Thread */ client.directMessage("Message to myself", "birchwood"); + + /** + * Test leaving multiple channels (multi) + */ + Thread.sleep(dur!("seconds")(2)); + client.leaveChannel(["#birchwood", "#birchwood2"]); + + /** + * Test leaving a single channel (singular) + */ + client.leaveChannel("#birchwoodLeave1"); + + /** + * Test leaving a single channel (multi) + */ + client.leaveChannel(["#birchwoodLeave2"]); + // TODO: Don't forget to re-enable this when done testing! Thread.sleep(dur!("seconds")(15)); client.quit();