diff --git a/irctest/server_tests/test_message_tags.py b/irctest/server_tests/test_message_tags.py index 3ab75af..6c0f76b 100644 --- a/irctest/server_tests/test_message_tags.py +++ b/irctest/server_tests/test_message_tags.py @@ -22,7 +22,12 @@ class MessageTagsTestCase(cases.BaseServerTestCase, cases.OptionalityHelper): self.assertEqual(msg.tags, {}) return msg - self.connectClient('alice', name='alice', capabilities=['message-tags']) + self.connectClient( + 'alice', + name='alice', + capabilities=['message-tags'], + skip_if_cap_nak=True + ) self.joinChannel('alice', '#test') self.connectClient('bob', name='bob', capabilities=['message-tags', 'echo-message']) self.joinChannel('bob', '#test') @@ -83,7 +88,12 @@ class MessageTagsTestCase(cases.BaseServerTestCase, cases.OptionalityHelper): @cases.SpecificationSelector.requiredBySpecification('message-tags') def testLengthLimits(self): - self.connectClient('alice', name='alice', capabilities=['message-tags', 'echo-message']) + self.connectClient( + 'alice', + name='alice', + capabilities=['message-tags', 'echo-message'], + skip_if_cap_nak=True + ) self.joinChannel('alice', '#test') self.connectClient('bob', name='bob', capabilities=['message-tags']) self.joinChannel('bob', '#test') diff --git a/irctest/server_tests/test_monitor.py b/irctest/server_tests/test_monitor.py index 5326796..f51ee87 100644 --- a/irctest/server_tests/test_monitor.py +++ b/irctest/server_tests/test_monitor.py @@ -272,7 +272,10 @@ class MonitorTestCase(cases.BaseServerTestCase): self.sendLine(2, 'NICK qux') self.getMessages(2) mononline = self.getMessages(1)[0] - self.assertMessageEqual(mononline, command=RPL_MONONLINE, params=['bar', 'qux']) + self.assertEqual(mononline.command, RPL_MONONLINE) + self.assertEqual(len(mononline.params), 2, mononline.params) + self.assertIn(mononline.params[0], ('bar', '*')) + self.assertEqual(mononline.params[1].split('!')[0], 'qux') # no numerics for a case change self.sendLine(2, 'NICK QUX') @@ -283,4 +286,7 @@ class MonitorTestCase(cases.BaseServerTestCase): self.getMessages(2) monoffline = self.getMessages(1)[0] # should get RPL_MONOFFLINE with the current unfolded nick - self.assertMessageEqual(monoffline, command=RPL_MONOFFLINE, params=['bar', 'QUX']) + self.assertEqual(monoffline.command, RPL_MONOFFLINE) + self.assertEqual(len(monoffline.params), 2, monoffline.params) + self.assertIn(monoffline.params[0], ('bar', '*')) + self.assertEqual(monoffline.params[1].split('!')[0], 'QUX') diff --git a/irctest/server_tests/test_multiline.py b/irctest/server_tests/test_multiline.py index 075f6d8..abdcc85 100644 --- a/irctest/server_tests/test_multiline.py +++ b/irctest/server_tests/test_multiline.py @@ -14,7 +14,9 @@ class MultilineTestCase(cases.BaseServerTestCase, cases.OptionalityHelper): @cases.SpecificationSelector.requiredBySpecification('multiline') def testBasic(self): - self.connectClient('alice', capabilities=(base_caps + [CAP_NAME])) + self.connectClient( + 'alice', capabilities=(base_caps + [CAP_NAME]), skip_if_cap_nak=True + ) self.joinChannel(1, '#test') self.connectClient('bob', capabilities=(base_caps + [CAP_NAME])) self.joinChannel(2, '#test') @@ -80,7 +82,9 @@ class MultilineTestCase(cases.BaseServerTestCase, cases.OptionalityHelper): @cases.SpecificationSelector.requiredBySpecification('multiline') def testBlankLines(self): - self.connectClient('alice', capabilities=(base_caps + [CAP_NAME])) + self.connectClient( + 'alice', capabilities=(base_caps + [CAP_NAME]), skip_if_cap_nak=True + ) self.joinChannel(1, '#test') self.connectClient('bob', capabilities=(base_caps + [CAP_NAME])) self.joinChannel(2, '#test') diff --git a/irctest/server_tests/test_regressions.py b/irctest/server_tests/test_regressions.py index db40cb9..7559845 100644 --- a/irctest/server_tests/test_regressions.py +++ b/irctest/server_tests/test_regressions.py @@ -56,7 +56,11 @@ class RegressionsTestCase(cases.BaseServerTestCase): @cases.SpecificationSelector.requiredBySpecification('IRCv3.2') def testTagCap(self): # regression test for oragono #754 - self.connectClient('alice', capabilities=['message-tags', 'batch', 'echo-message', 'server-time']) + self.connectClient( + 'alice', + capabilities=['message-tags', 'batch', 'echo-message', 'server-time'], + skip_if_cap_nak=True + ) self.connectClient('bob') self.getMessages(1) self.getMessages(2)