From 24d4ba2162efaac86ea076efbef3a61d7c85b82b Mon Sep 17 00:00:00 2001 From: CPython Developers <> Date: Mon, 9 Feb 2026 15:19:54 +0900 Subject: [PATCH] Update test_errno from v3.14.3 --- Lib/test/test_errno.py | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) diff --git a/Lib/test/test_errno.py b/Lib/test/test_errno.py index 5c437e9cc..e7f185c6b 100644 --- a/Lib/test/test_errno.py +++ b/Lib/test/test_errno.py @@ -12,14 +12,12 @@ class ErrnoAttributeTests(unittest.TestCase): def test_for_improper_attributes(self): # No unexpected attributes should be on the module. for error_code in std_c_errors: - self.assertTrue(hasattr(errno, error_code), - "errno is missing %s" % error_code) + self.assertHasAttr(errno, error_code) def test_using_errorcode(self): # Every key value in errno.errorcode should be on the module. for value in errno.errorcode.values(): - self.assertTrue(hasattr(errno, value), - 'no %s attr in errno' % value) + self.assertHasAttr(errno, value) class ErrorcodeTests(unittest.TestCase):