+
     ]i  c                   s    ^ RI Ht ^ RIt^ RIt^ RIHt ^ RIHt ^ RIHt ]P                  P                  R. RO4      R 4       tR# )	    )PathN)approx)compare_images)_image_directorieszim1, im2, tol, expect_rmsc                s,   VP                  V4       \        \        \        R 4      4      w  rgWp,          p\        P
                  ! Wa,          V4       \        W`,          WRR7      p	Vf	   V	e   Q hR# V	f   Q hV	R,          \        VRR7      8X  g   Q hR# )a  
Compare two images, expecting a particular RMS error.

im1 and im2 are filenames relative to the baseline_dir directory.

tol is the tolerance to pass to compare_images.

expect_rms is the expected RMS value, or None. If None, the test will
succeed if compare_images succeeds. Otherwise, the test will succeed if
compare_images fails and returns an RMS error almost equal to this value.
c                  s    R # )Zdummy r       K/usr/lib64/python3.14/site-packages/matplotlib/tests/test_compare_images.pyZ<lambda>Z2test_image_comparison_expect_rms.<locals>.<lambda>=   s    Gr   T)tolZin_decoratorNZrmsg-C6?)Zabs)ZchdirZmapr   r   shutilZcopyfiler   r   )
Zim1Zim2r   Z
expect_rmsZtmp_pathZmonkeypatchZbaseline_dirZ
result_dirZ
result_im2Zresultss
   &&&&&&    r    test_image_comparison_expect_rmsr
      s    ` h"4);O)LML !J
OOL&
3JdDG """u~
!====r   ))basn3p02.pngbasn3p02-minorchange.pngi
   N)r   r   r    gBs@)r   zbasn3p02-1px-offset.pngr    g%̴V@)r   zbasn3p02-half-1px-offset.pngr    g     O@)r   zbasn3p02-scrambled.pngr    gD/Xe@)
all127.png
all128.pngr       )r   r   r    r   )Zpathlibr   r	   Zpytestr   Zmatplotlib.testing.comparer   Zmatplotlib.testing.decoratorsr   ZmarkZparametrizer
   r   r   r   <module>r      sE        5 <  B>C B>r   