.. title:: pytest-mpl documentation .. module:: pytest-mpl .. toctree:: :hidden: installing usage image_mode hash_mode hybrid_mode configuration ################################## pytest-mpl |release| documentation ################################## ``pytest-mpl`` is a `pytest `__ plugin to facilitate image comparison for `Matplotlib `__ figures. For each figure to test, an image is generated and then subtracted from an existing reference image. If the RMS of the residual is larger than a user-specified tolerance, the test will fail. Alternatively, the generated image can be hashed and compared to an expected value. ************ Installation ************ .. grid:: 1 1 2 2 .. grid-item:: Install using `pip `__: .. code-block:: bash pip install pytest-mpl .. grid-item:: Install from `conda-forge `__ using `conda `__: .. code-block:: bash conda install pytest-mpl Further details are available in the :doc:`Installation Guide `. ****************** Learning resources ****************** .. grid:: 1 1 2 2 .. grid-item-card:: :padding: 2 Tutorials ^^^ - :doc:`Get started ` .. grid-item-card:: :padding: 2 How-tos ^^^ - :doc:`Image comparison mode ` - :doc:`Hash comparison mode ` - :doc:`Hybrid mode ` .. grid-item-card:: :padding: 2 Understand how pytest-mpl works ^^^ Explanatory information is included where relevant throughout the documentation. .. grid-item-card:: :padding: 2 Reference ^^^ - :doc:`Configuration ` ************ Contributing ************ ``pytest-mpl`` is a community project maintained for and by its users. There are many ways you can help! - Report a bug or request a feature `on GitHub `__ - Improve the documentation or code