From a65b8c91f7fc207b17466e77ab814848b186b077 Mon Sep 17 00:00:00 2001 From: Ales Erjavec Date: Wed, 6 Nov 2019 10:59:51 +0100 Subject: [PATCH] Add simple test for setEnableMenu --- pyqtgraph/graphicsItems/ViewBox/tests/test_ViewBox.py | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/pyqtgraph/graphicsItems/ViewBox/tests/test_ViewBox.py b/pyqtgraph/graphicsItems/ViewBox/tests/test_ViewBox.py index 5a8ca141..9495bfc3 100644 --- a/pyqtgraph/graphicsItems/ViewBox/tests/test_ViewBox.py +++ b/pyqtgraph/graphicsItems/ViewBox/tests/test_ViewBox.py @@ -74,6 +74,14 @@ def test_ViewBox(): win.close() +def test_ViewBox_setMenuEnabled(): + init_viewbox() + vb.setMenuEnabled(True) + assert vb.menu is not None + vb.setMenuEnabled(False) + assert vb.menu is None + + skipreason = "Skipping this test until someone has time to fix it." @pytest.mark.skipif(True, reason=skipreason) def test_limits_and_resize():