@@ -701,11 +701,7 @@ def test_insetposition():
701701@image_comparison (['imagegrid_cbar_mode.png' ],
702702 remove_text = True , style = 'mpl20' , tol = 0.3 )
703703def test_imagegrid_cbar_mode_edge ():
704- # Remove this line when this test image is regenerated.
705- plt .rcParams ['pcolormesh.snap' ] = False
706-
707- X , Y = np .meshgrid (np .linspace (0 , 6 , 30 ), np .linspace (0 , 6 , 30 ))
708- arr = np .sin (X ) * np .cos (Y ) + 1j * (np .sin (3 * Y ) * np .cos (Y / 2. ))
704+ arr = np .arange (16 ).reshape ((4 , 4 ))
709705
710706 fig = plt .figure (figsize = (18 , 9 ))
711707
@@ -721,12 +717,12 @@ def test_imagegrid_cbar_mode_edge():
721717 cbar_location = location ,
722718 cbar_size = '20%' ,
723719 cbar_mode = 'edge' )
724- ax1 , ax2 , ax3 , ax4 , = grid
720+ ax1 , ax2 , ax3 , ax4 = grid
725721
726- ax1 .imshow (arr . real , cmap = 'nipy_spectral' )
727- ax2 .imshow (arr .imag , cmap = 'hot' )
728- ax3 .imshow (np .abs (arr ), cmap = 'jet' )
729- ax4 .imshow (np .arctan2 (arr . imag , arr .real ), cmap = 'hsv' )
722+ ax1 .imshow (arr , cmap = 'nipy_spectral' )
723+ ax2 .imshow (arr .T , cmap = 'hot' )
724+ ax3 .imshow (np .hypot (arr , arr . T ), cmap = 'jet' )
725+ ax4 .imshow (np .arctan2 (arr , arr .T ), cmap = 'hsv' )
730726
731727 # In each row/column, the "first" colorbars must be overwritten by the
732728 # "second" ones. To achieve this, clear out the axes first.
0 commit comments