mirror of
https://github.com/weechat/weechat.git
synced 2026-06-30 14:56:39 +02:00
tests: add tests on function irc_protocol_cb_chghost
This commit is contained in:
@@ -363,6 +363,29 @@ TEST(IrcProtocolWithServer, away)
|
||||
LONGS_EQUAL(1, ptr_nick->away);
|
||||
}
|
||||
|
||||
/*
|
||||
* Tests functions:
|
||||
* irc_protocol_cb_chghost
|
||||
*/
|
||||
|
||||
TEST(IrcProtocolWithServer, chghost)
|
||||
{
|
||||
struct t_irc_nick *ptr_nick;
|
||||
|
||||
server_recv (":server 001 alice");
|
||||
server_recv (":alice!user@host JOIN #test");
|
||||
|
||||
ptr_nick = ptr_server->channels->nicks;
|
||||
|
||||
STRCMP_EQUAL("user@host", ptr_nick->host);
|
||||
|
||||
server_recv (":alice!user@host CHGHOST user2 host2");
|
||||
STRCMP_EQUAL("user2@host2", ptr_nick->host);
|
||||
|
||||
server_recv (":alice!user2@host2 CHGHOST user3 :host3");
|
||||
STRCMP_EQUAL("user3@host3", ptr_nick->host);
|
||||
}
|
||||
|
||||
/*
|
||||
* Tests functions:
|
||||
* irc_protocol_cb_001 (empty)
|
||||
|
||||
Reference in New Issue
Block a user