mirror of
https://github.com/python/cpython.git
synced 2025-08-30 21:48:47 +00:00
#10273: Remove a "Matches" that I missed in r86910. Thanks to RDM for noticing it.
This commit is contained in:
parent
522cc0a9a1
commit
8f77630747
2 changed files with 5 additions and 5 deletions
|
@ -92,15 +92,15 @@ class Test_Assertions(unittest.TestCase):
|
|||
else:
|
||||
self.fail("assertRaises() didn't let exception pass through")
|
||||
|
||||
def testAssertNotRegexMatches(self):
|
||||
self.assertNotRegexMatches('Ala ma kota', r'r+')
|
||||
def testAssertNotRegex(self):
|
||||
self.assertNotRegex('Ala ma kota', r'r+')
|
||||
try:
|
||||
self.assertNotRegexMatches('Ala ma kota', r'k.t', 'Message')
|
||||
self.assertNotRegex('Ala ma kota', r'k.t', 'Message')
|
||||
except self.failureException as e:
|
||||
self.assertIn("'kot'", e.args[0])
|
||||
self.assertIn('Message', e.args[0])
|
||||
else:
|
||||
self.fail('assertNotRegexMatches should have failed.')
|
||||
self.fail('assertNotRegex should have failed.')
|
||||
|
||||
|
||||
class TestLongMessage(unittest.TestCase):
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue