Make testDirectMessageEcho not Oragono-specific

This commit is contained in:
2021-02-27 11:04:57 +01:00
committed by Valentin Lorentz
parent f7be6cf016
commit daa182bcd2

View File

@ -7,20 +7,19 @@ from irctest.basecontrollers import NotImplementedByController
from irctest.irc_utils.junkdrawer import random_name from irctest.irc_utils.junkdrawer import random_name
class DMEchoMessageTestCase(cases.BaseServerTestCase): class EchoMessageTestCase(cases.BaseServerTestCase):
@cases.mark_specifications("Oragono") @cases.mark_capabilities("labeled-response", "echo-message", "message-tags")
def testDirectMessageEcho(self): def testDirectMessageEcho(self):
bar = random_name("bar") bar = random_name("bar")
self.connectClient( self.connectClient(
bar, bar,
name=bar, name=bar,
capabilities=[ capabilities=[
"batch",
"labeled-response", "labeled-response",
"echo-message", "echo-message",
"message-tags", "message-tags",
"server-time",
], ],
skip_if_cap_nak=True,
) )
self.getMessages(bar) self.getMessages(bar)
@ -29,11 +28,9 @@ class DMEchoMessageTestCase(cases.BaseServerTestCase):
qux, qux,
name=qux, name=qux,
capabilities=[ capabilities=[
"batch",
"labeled-response", "labeled-response",
"echo-message", "echo-message",
"message-tags", "message-tags",
"server-time",
], ],
) )
self.getMessages(qux) self.getMessages(qux)
@ -62,8 +59,6 @@ class DMEchoMessageTestCase(cases.BaseServerTestCase):
delivery.tags["+example-client-tag"], echo.tags["+example-client-tag"] delivery.tags["+example-client-tag"], echo.tags["+example-client-tag"]
) )
class EchoMessageTestCase(cases.BaseServerTestCase):
def _testEchoMessage(command, solo, server_time): def _testEchoMessage(command, solo, server_time):
@cases.mark_capabilities("echo-message") @cases.mark_capabilities("echo-message")
def f(self): def f(self):