Skip to content

Commit

Permalink
Merge pull request #185 from ConorMacBride/doc-return-warning
Browse files Browse the repository at this point in the history
Add documentation on avoiding `PytestReturnNotNoneWarning`
  • Loading branch information
Cadair committed Nov 4, 2022
2 parents 5b5f6da + e4dca96 commit 3a19c2f
Show file tree
Hide file tree
Showing 2 changed files with 10 additions and 0 deletions.
5 changes: 5 additions & 0 deletions README.rst
Original file line number Diff line number Diff line change
Expand Up @@ -120,6 +120,11 @@ and the tests will pass if the images are the same. If you omit the
``--mpl`` option, the tests will run but will only check that the code
runs, without checking the output images.

If pytest-mpl is not installed, the image comparison tests will cause pytest
to show a warning, ``PytestReturnNotNoneWarning``. Installing pytest-mpl will
solve this issue. Alternativly, the image comparison tests can be deselected
by running pytest with ``-m "not mpl_image_compare"``.


Generating a Test Summary
^^^^^^^^^^^^^^^^^^^^^^^^^
Expand Down
5 changes: 5 additions & 0 deletions docs/usage.rst
Original file line number Diff line number Diff line change
Expand Up @@ -86,3 +86,8 @@ against, the tests can be run with::
and the tests will pass if the images are the same. If you omit the
``--mpl`` option, the tests will run but will only check that the code
runs, without checking the output images.

If pytest-mpl is not installed, the image comparison tests will cause pytest
to show a warning, ``PytestReturnNotNoneWarning``. Installing pytest-mpl will
solve this issue. Alternativly, the image comparison tests can be deselected
by running pytest with ``-m "not mpl_image_compare"``.

0 comments on commit 3a19c2f

Please sign in to comment.