diff options
author | Serhiy Storchaka <storchaka@gmail.com> | 2013-11-16 10:56:23 (GMT) |
---|---|---|
committer | Serhiy Storchaka <storchaka@gmail.com> | 2013-11-16 10:56:23 (GMT) |
commit | 328cf3cbdfd6b09d4eae496b746e5013291e6aca (patch) | |
tree | a7592a406b0d34aff2f110ce9d45fea2aec25378 /Lib/test/test_email/test_parser.py | |
parent | 9c10d6b8000e445093e73c295ad87b5e081902f7 (diff) | |
download | cpython-328cf3cbdfd6b09d4eae496b746e5013291e6aca.zip cpython-328cf3cbdfd6b09d4eae496b746e5013291e6aca.tar.gz cpython-328cf3cbdfd6b09d4eae496b746e5013291e6aca.tar.bz2 |
Issue #19590: Use specific asserts in email tests.
Diffstat (limited to 'Lib/test/test_email/test_parser.py')
-rw-r--r-- | Lib/test/test_email/test_parser.py | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/Lib/test/test_email/test_parser.py b/Lib/test/test_email/test_parser.py index 3abd11a..b54fdd7 100644 --- a/Lib/test/test_email/test_parser.py +++ b/Lib/test/test_email/test_parser.py @@ -18,7 +18,7 @@ class TestCustomMessage(TestEmailBase): msg = email.message_from_string("Subject: bogus\n\nmsg\n", self.MyMessage, policy=self.MyPolicy) - self.assertTrue(isinstance(msg, self.MyMessage)) + self.assertIsInstance(msg, self.MyMessage) self.assertIs(msg.check_policy, self.MyPolicy) def test_custom_message_gets_policy_if_possible_from_file(self): @@ -26,7 +26,7 @@ class TestCustomMessage(TestEmailBase): msg = email.message_from_file(source_file, self.MyMessage, policy=self.MyPolicy) - self.assertTrue(isinstance(msg, self.MyMessage)) + self.assertIsInstance(msg, self.MyMessage) self.assertIs(msg.check_policy, self.MyPolicy) # XXX add tests for other functions that take Message arg. |