From cd408707814850a31d810372fc7be2153aefa6be Mon Sep 17 00:00:00 2001 From: "Andrew J. Hesford" Date: Sat, 23 Sep 2023 21:01:40 -0400 Subject: [PATCH] python3-QtPy: update to 2.3.1, test with PyQt6 --- srcpkgs/python3-QtPy/template | 40 ++++++++++++++++++++--------------- 1 file changed, 23 insertions(+), 17 deletions(-) diff --git a/srcpkgs/python3-QtPy/template b/srcpkgs/python3-QtPy/template index e6753ea5cc9..10563bde6b2 100644 --- a/srcpkgs/python3-QtPy/template +++ b/srcpkgs/python3-QtPy/template @@ -1,31 +1,37 @@ # Template file for 'python3-QtPy' pkgname=python3-QtPy -version=2.3.0 +version=2.3.1 revision=1 -build_style=python3-module -hostmakedepends="python3-setuptools" -# depends on any of PySide2 PyQt5 +build_style=python3-pep517 +hostmakedepends="python3-setuptools python3-wheel" +# depends on either of PyQt5, PyQt6 depends="python3" -checkdepends="python3-pytest python3-mock python3-pyside2-webengine - python3-PyQt5-sql python3-PyQt5-svg python3-PyQt5-webengine - python3-PyQt5-websockets python3-PyQt5-xmlpatterns python3-PyQt5-quick - python3-PyQt5-multimedia python3-PyQt5-location python3-PyQt5-tools" +# Packages common to both PyQt5 and PyQt6 +_qtcommon="python3-PyQt5-sql python3-PyQt5-svg python3-PyQt5-webengine + python3-PyQt5-websockets python3-PyQt5-multimedia python3-PyQt5-tools" +checkdepends="python3-pytest python3-mock python3-pyqt6-declarative + python3-pyqt6-widgets python3-pyqt6-gui python3-pyqt6-opengl-widgets + python3-pyqt6-printsupport python3-pyqt6-network python3-pyqt6-devel-tools + python3-pyqt6-test python3-pyqt6-webchannel python3-pyqt6-xml + qt6-plugin-sqlite python3-PyQt5-quick python3-PyQt5-xmlpatterns + python3-PyQt5-location python3-PyQt5-opengl qt5-plugin-sqlite ${_qtcommon} + ${_qtcommon//PyQt5/pyqt6}" short_desc="Abstraction layer on top of various Python Qt bindings" maintainer="Orphaned " license="MIT" homepage="https://github.com/spyder-ide/qtpy" distfiles="${PYPI_SITE}/Q/QtPy/QtPy-${version}.tar.gz" -checksum=0603c9c83ccc035a4717a12908bf6bc6cb22509827ea2ec0e94c2da7c9ed57c5 - -post_patch() { - # Both of those tests are failing inside chroot, - # but success outside of chroot - rm -f qtpy/tests/test_patch_qcombobox.py -} +checksum=a8c74982d6d172ce124d80cafd39653df78989683f760f2281ba91a6e7b9de8b do_check() { - CI=1 QT_API=PyQt5 FORCE_QT_API=PyQt5 pytest -k 'not test_load_ui' - CI=1 QT_API=PySide2 FORCE_QT_API=PySide2 pytest + local qtapi + + rm -f pytest.ini + + for qtapi in pyqt5 pyqt6; do + CI=1 USE_QT_API="${qtapi}" QT_API="${qtapi}" \ + python3 -m pytest -k 'not test_qttexttospeech' qtpy/tests + done } post_install() {