diff --git a/Tests/test_imageshow.py b/Tests/test_imageshow.py index 67c32783f..7a2f58767 100644 --- a/Tests/test_imageshow.py +++ b/Tests/test_imageshow.py @@ -117,5 +117,5 @@ def test_ipythonviewer() -> None: else: pytest.fail("IPythonViewer not found") - im = hopper() - assert test_viewer.show(im) == 1 + with hopper() as im: + assert test_viewer.show(im) == 1