plugins/Owner: Update some tests to how they should be written. Now we just need to get the code to work correctly.

This commit is contained in:
James Vega 2005-05-11 01:00:01 +00:00
parent 106fbc6eea
commit 170d735c91

View File

@ -39,7 +39,7 @@ class OwnerTestCase(PluginTestCase):
self.assertHelp('help log') self.assertHelp('help log')
def testSrcAmbiguity(self): def testSrcAmbiguity(self):
self.assertError('addcapability foo bar') self.assertError('capability add foo bar')
def testIrcquote(self): def testIrcquote(self):
self.assertResponse('ircquote PRIVMSG %s :foo' % self.irc.nick, 'foo') self.assertResponse('ircquote PRIVMSG %s :foo' % self.irc.nick, 'foo')
@ -84,14 +84,14 @@ class OwnerTestCase(PluginTestCase):
def testRename(self): def testRename(self):
self.assertError('rename Admin ignore IGNORE') self.assertError('rename Admin ignore IGNORE')
self.assertError('rename Admin ignore ig-nore') self.assertError('rename Admin ignore ig-nore')
self.assertNotError('rename Admin removecapability rmcap') self.assertNotError('rename Admin "capability remove" rmcap')
self.assertNotRegexp('list Admin', 'removecapability') self.assertNotRegexp('list Admin', 'capability remove')
self.assertRegexp('list Admin', 'rmcap') self.assertRegexp('list Admin', 'rmcap')
self.assertNotError('reload Admin') self.assertNotError('reload Admin')
self.assertNotRegexp('list Admin', 'removecapability') self.assertNotRegexp('list Admin', 'capability remove')
self.assertRegexp('list Admin', 'rmcap') self.assertRegexp('list Admin', 'rmcap')
self.assertNotError('unrename Admin') self.assertNotError('unrename Admin')
self.assertRegexp('list Admin', 'removecapability') self.assertRegexp('list Admin', 'capability remove')
self.assertNotRegexp('list Admin', 'rmcap') self.assertNotRegexp('list Admin', 'rmcap')
def testDefaultPluginErrorsWhenCommandNotInPlugin(self): def testDefaultPluginErrorsWhenCommandNotInPlugin(self):