We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
2 parents 89183ba + 7c06c7f commit d5e10feCopy full SHA for d5e10fe
lib/matplotlib/tests/test_image.py
@@ -806,10 +806,12 @@ def test_imshow_flatfield():
806
colors.LogNorm,
807
lambda: colors.SymLogNorm(1),
808
lambda: colors.PowerNorm(1)])
809
-@pytest.mark.filterwarnings("ignore:Attempting to set identical left==right")
810
def test_empty_imshow(make_norm):
811
fig, ax = plt.subplots()
812
- im = ax.imshow([[]], norm=make_norm())
+ with warnings.catch_warnings():
+ warnings.filterwarnings(
813
+ "ignore", "Attempting to set identical left==right")
814
+ im = ax.imshow([[]], norm=make_norm())
815
im.set_extent([-5, 5, -5, 5])
816
fig.canvas.draw()
817
0 commit comments