mirror of
https://github.com/Mikaela/Limnoria.git
synced 2024-12-25 04:02:46 +01:00
Quote: add tests for 'replace'
This commit is contained in:
parent
93d94067d0
commit
53792fbe6c
@ -29,8 +29,15 @@
|
|||||||
|
|
||||||
from supybot.test import *
|
from supybot.test import *
|
||||||
|
|
||||||
class QuoteTestCase(PluginTestCase):
|
class QuoteTestCase(ChannelPluginTestCase):
|
||||||
plugins = ('Quote',)
|
plugins = ('Quote', 'User')
|
||||||
|
|
||||||
|
def testReplace(self):
|
||||||
|
self.feedMsg('register testuser moo', to=self.nick, frm=self.prefix)
|
||||||
|
_ = self.getMsg(' ')
|
||||||
|
self.assertNotError("quote add hello")
|
||||||
|
self.assertNotError("quote replace 1 goodbye")
|
||||||
|
self.assertRegexp("quote get 1", "goodbye")
|
||||||
|
self.assertError("quote replace 5 afsdafas") # non-existant
|
||||||
|
|
||||||
# vim:set shiftwidth=4 softtabstop=4 expandtab textwidth=79:
|
# vim:set shiftwidth=4 softtabstop=4 expandtab textwidth=79:
|
||||||
|
Loading…
Reference in New Issue
Block a user