bot_mode: Make draft/ prefix optional (#167)

The spec is ratified.
This commit is contained in:
2022-04-28 20:38:49 +02:00
committed by GitHub
parent 8c73ac2b75
commit 641bea5f0a

View File

@ -1,5 +1,5 @@
""" """
`IRCv3 draft bot mode <https://ircv3.net/specs/extensions/bot-mode>`_ `IRCv3 bot mode <https://ircv3.net/specs/extensions/bot-mode>`_
""" """
from irctest import cases, runner from irctest import cases, runner
@ -85,7 +85,7 @@ class BotModeTestCase(cases.BaseServerTestCase):
self.getMessage("user"), self.getMessage("user"),
command="PRIVMSG", command="PRIVMSG",
params=["usernick", "beep boop"], params=["usernick", "beep boop"],
tags={"draft/bot": None, **ANYDICT}, tags={StrRe("(draft/)?bot"): None, **ANYDICT},
) )
@cases.xfailIfSoftware( @cases.xfailIfSoftware(
@ -111,7 +111,7 @@ class BotModeTestCase(cases.BaseServerTestCase):
self.getMessage("user"), self.getMessage("user"),
command="PRIVMSG", command="PRIVMSG",
params=["#chan", "beep boop"], params=["#chan", "beep boop"],
tags={"draft/bot": None, **ANYDICT}, tags={StrRe("(draft/)?bot"): None, **ANYDICT},
) )
def testBotWhox(self): def testBotWhox(self):