enable matplotlib exporter test for qt6

This commit is contained in:
KIU Shueng Chuan 2021-08-06 10:34:43 +08:00
parent 8d3e6cbd22
commit 4b59734629

View File

@ -3,13 +3,15 @@ import pytest
import pyqtgraph as pg import pyqtgraph as pg
from pyqtgraph.exporters import MatplotlibExporter from pyqtgraph.exporters import MatplotlibExporter
pytest.importorskip("matplotlib") pytest.importorskip("matplotlib")
import matplotlib
app = pg.mkQApp() app = pg.mkQApp()
skip_qt6 = pytest.mark.skipif( 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= ( reason= (
"Matplotlib has no Qt6 support yet, " "installed version of Matplotlib does not support Qt6, "
"see https://github.com/matplotlib/matplotlib/pull/19255" "see https://github.com/matplotlib/matplotlib/pull/19255"
) )
) )