mirror of
https://github.com/Mikaela/Limnoria.git
synced 2024-11-23 11:09:23 +01:00
Added more tests for the lexer, to make sure stuff within dangling parens is
left alone.
This commit is contained in:
parent
9d8d47bbe7
commit
473ce16776
@ -45,6 +45,12 @@ if sqlite is not None:
|
||||
def testNoBarParens(self):
|
||||
self.assertEqual(MoobotFactoids.tokenize('(foo)'), ['(foo)'])
|
||||
|
||||
def testDanglingParens(self):
|
||||
self.assertEqual(MoobotFactoids.tokenize('(foo'), ['(foo'])
|
||||
self.assertEqual(MoobotFactoids.tokenize('(foo|bar'),['(foo|bar'])
|
||||
self.assertEqual(MoobotFactoids.tokenize('foo)'), ['foo)'])
|
||||
self.assertEqual(MoobotFactoids.tokenize('foo|bar)'),['foo|bar)'])
|
||||
|
||||
class FactoidsTestCase(PluginTestCase, PluginDocumentation):
|
||||
plugins = ('MoobotFactoids', 'User', 'Utilities')
|
||||
def setUp(self):
|
||||
|
Loading…
Reference in New Issue
Block a user