Aka, Google, String: fix more DeprecationWarning in tests (#1328)

This commit is contained in:
James Lu 2020-01-26 11:31:22 -08:00
parent 358c3a741f
commit 4528a847e4
3 changed files with 4 additions and 4 deletions

View File

@ -267,9 +267,9 @@ class AkaTestCase(PluginTestCase):
def testList(self):
self.assertNotError('aka add foo bar')
self.assertRegexp('aka list', 'foo.*?bar \$\*')
self.assertRegexp('aka list', r'foo.*?bar \$\*')
self.assertNotError('aka add "foo bar" baz')
self.assertRegexp('aka list', 'foo.*?bar \$\*.*?foo bar.*?baz \$\*')
self.assertRegexp('aka list', r'foo.*?bar \$\*.*?foo bar.*?baz \$\*')
def testListLockedUnlocked(self):
self.assertNotError('register tacocat hunter2')

View File

@ -58,7 +58,7 @@ class GoogleTestCase(ChannelPluginTestCase):
self.assertRegexp(
'google site:http://www.urbandictionary.com carajo land',
'\x02Urban Dictionary: carajo land\x02: '
'https?://www.urbandictionary.com/define.php\?term=carajo%20land')
r'https?://www.urbandictionary.com/define.php\?term=carajo%20land')
def testLucky(self):
self.assertResponse('lucky Hacker News',

View File

@ -130,7 +130,7 @@ class StringTestCase(PluginTestCase):
self.assertNotRegexp('re foo bar baz', 'unpack list of wrong size')
def testReBug850931(self):
self.assertResponse('re s/\b(\w+)\b/\1./g foo bar baz',
self.assertResponse(r're s/\b(\w+)\b/\1./g foo bar baz',
'foo. bar. baz.')
def testNotOverlongRe(self):