Skip to content
This repository has been archived by the owner on Oct 1, 2024. It is now read-only.

Commit

Permalink
Update writing_tests.rst
Browse files Browse the repository at this point in the history
  • Loading branch information
darrenburns authored Jun 25, 2021
1 parent a2ef8b3 commit fb5c216
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions docs/source/guide/writing_tests.rst
Original file line number Diff line number Diff line change
Expand Up @@ -248,6 +248,9 @@ use ``with raises(<exc_type>) as <exc_object>``:
Note that ``ex`` is only populated after the context manager exits, so
be careful with your indentation.

If an instance of a *subclass* of the exception you pass to ``raises`` is raised by the code
under test, ``raises`` will catch that too.

.. _async_tests:

Testing `async` code
Expand Down

0 comments on commit fb5c216

Please sign in to comment.