@@ -286,9 +286,10 @@ in ``mpl_image_compare``. Supported formats are ``'eps'``, ``'pdf'``, ``'png'``,
286286Note that Ghostscript is required to be installed for comparing PDF and EPS figures, while
287287Inkscape is required for SVG comparison.
288288
289- By default, Matplotlib does not produce deterministic output that will
290- have a consistent hash every time it is run, or over different Matplotlib versions.
291- In order to enforce that the output is deterministic, you will need to do the following:
289+ By default, Matplotlib does not produce deterministic output that will have a
290+ consistent hash every time it is run, or over different Matplotlib versions. In
291+ order to enforce that the output is deterministic, you will need to set metadata
292+ as described in the following subsections.
292293
293294PNG
294295^^^
@@ -311,6 +312,8 @@ For PDF files, the output can be made deterministic by setting:
311312 " Producer" : None ,
312313 " CreationDate" : None }})
313314
315+ Note that deterministic PDF output can only be achieved with Matplotlib 2.1 and above
316+
314317EPS
315318^^^
316319
@@ -330,6 +333,8 @@ a constant value (this is a unit timestamp):
330333
331334You could do this inside the test.
332335
336+ Note that deterministic PDF output can only be achieved with Matplotlib 2.1 and above
337+
333338SVG
334339^^^
335340
@@ -345,6 +350,8 @@ and in addition, you should make sure the following rcParam is set to a constant
345350
346351 plt.rcParams[' svg.hashsalt' ] = ' test'
347352
353+ Note that SVG files can only be used in pytest- mpl with Matplotlib 3.3 and above.
354+
348355Test failure example
349356--------------------
350357
0 commit comments