summaryrefslogtreecommitdiff
path: root/tests/unit/plugins/irc
diff options
context:
space:
mode:
authorSébastien Helleu <flashcode@flashtux.org>2023-11-07 21:58:04 +0100
committerSébastien Helleu <flashcode@flashtux.org>2023-11-07 21:58:04 +0100
commitecc900ba3adaac84bbdfabe235a06113f1986ab7 (patch)
tree19040e802cc6704d5912d81caad49c6a2c0bb4fd /tests/unit/plugins/irc
parent515d4241ad471ef1ca4d012ba4c8e5dfc79f3488 (diff)
downloadweechat-ecc900ba3adaac84bbdfabe235a06113f1986ab7.zip
tests: add tests on IRC message 337
Diffstat (limited to 'tests/unit/plugins/irc')
-rw-r--r--tests/unit/plugins/irc/test-irc-protocol.cpp11
1 files changed, 10 insertions, 1 deletions
diff --git a/tests/unit/plugins/irc/test-irc-protocol.cpp b/tests/unit/plugins/irc/test-irc-protocol.cpp
index bd642a122..f394c0dab 100644
--- a/tests/unit/plugins/irc/test-irc-protocol.cpp
+++ b/tests/unit/plugins/irc/test-irc-protocol.cpp
@@ -3619,7 +3619,8 @@ TEST(IrcProtocolWithServer, 221)
* 319: whois (channels)
* 320: whois (identified user)
* 326: whois (has oper privs)
- * 335: is a bot on
+ * 335: whois (is a bot on)
+ * 337: whois ((is hiding idle time)
* 378: whois (connecting from)
* 379: whois (using modes)
* 671: whois (secure connection)
@@ -3678,6 +3679,10 @@ TEST(IrcProtocolWithServer, whois_nick_msg)
CHECK_ERROR_PARAMS("335", 0, 2);
RECV(":server 335 alice");
CHECK_ERROR_PARAMS("335", 1, 2);
+ RECV(":server 337");
+ CHECK_ERROR_PARAMS("337", 0, 2);
+ RECV(":server 337 alice");
+ CHECK_ERROR_PARAMS("337", 1, 2);
RECV(":server 378");
CHECK_ERROR_PARAMS("378", 0, 2);
RECV(":server 378 alice");
@@ -3744,6 +3749,10 @@ TEST(IrcProtocolWithServer, whois_nick_msg)
CHECK_SRV("--", "[bob] is a bot", "irc_335,irc_numeric,nick_server,log3");
RECV(":server 335 alice bob");
CHECK_SRV("--", "bob", "irc_335,irc_numeric,nick_server,log3");
+ RECV(":server 337 alice bob :is hiding their idle time");
+ CHECK_SRV("--", "[bob] is hiding their idle time", "irc_337,irc_numeric,nick_server,log3");
+ RECV(":server 337 alice bob");
+ CHECK_SRV("--", "bob", "irc_337,irc_numeric,nick_server,log3");
RECV(":server 378 alice bob");
CHECK_SRV("--", "bob", "irc_378,irc_numeric,nick_server,log3");
RECV(":server 378 alice bob :connecting from");