From 4b5973462981f99d7cd3cb394d66093ec4c56e33 Mon Sep 17 00:00:00 2001 From: KIU Shueng Chuan Date: Fri, 6 Aug 2021 10:34:43 +0800 Subject: [PATCH] enable matplotlib exporter test for qt6 --- tests/exporters/test_matplotlib.py | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/tests/exporters/test_matplotlib.py b/tests/exporters/test_matplotlib.py index 1e4468b7..4dfed621 100644 --- a/tests/exporters/test_matplotlib.py +++ b/tests/exporters/test_matplotlib.py @@ -3,13 +3,15 @@ import pytest import pyqtgraph as pg from pyqtgraph.exporters import MatplotlibExporter pytest.importorskip("matplotlib") +import matplotlib app = pg.mkQApp() skip_qt6 = pytest.mark.skipif( - pg.Qt.QT_LIB in ["PySide6", "PyQt6"], + # availability of QtAgg signifies Qt6 support + pg.Qt.QT_LIB in ["PySide6", "PyQt6"] and "QtAgg" not in matplotlib.rcsetup.interactive_bk, reason= ( - "Matplotlib has no Qt6 support yet, " + "installed version of Matplotlib does not support Qt6, " "see https://github.com/matplotlib/matplotlib/pull/19255" ) )