]> git.ipfire.org Git - thirdparty/Python/cpython.git/commitdiff
gh-149663: fix typo in `unittest` docs (#149670)
authorÁrni Már Jónsson <arnimarj@gmail.com>
Mon, 11 May 2026 11:54:09 +0000 (11:54 +0000)
committerGitHub <noreply@github.com>
Mon, 11 May 2026 11:54:09 +0000 (14:54 +0300)
`hastattr` -> `hasattr`

Doc/library/unittest.rst

index c54f3e2792c3888ecdb5c80caecd2972e149b999..ff619f97923325120bf01d0965c08f539ef8b708 100644 (file)
@@ -1262,10 +1262,10 @@ Test cases
    | :meth:`assertNotEndsWith(a, b)        | ``not a.endswith(b)``          | 3.14         |
    | <TestCase.assertNotEndsWith>`         |                                |              |
    +---------------------------------------+--------------------------------+--------------+
-   | :meth:`assertHasAttr(a, b)            | ``hastattr(a, b)``             | 3.14         |
+   | :meth:`assertHasAttr(a, b)            | ``hasattr(a, b)``              | 3.14         |
    | <TestCase.assertHasAttr>`             |                                |              |
    +---------------------------------------+--------------------------------+--------------+
-   | :meth:`assertNotHasAttr(a, b)         | ``not hastattr(a, b)``         | 3.14         |
+   | :meth:`assertNotHasAttr(a, b)         | ``not hasattr(a, b)``          | 3.14         |
    | <TestCase.assertNotHasAttr>`          |                                |              |
    +---------------------------------------+--------------------------------+--------------+