Thanks to visit codestin.com
Credit goes to github.com

Skip to content
Merged
Show file tree
Hide file tree
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Next Next commit
enable more test on CI
  • Loading branch information
Czaki committed Jun 3, 2023
commit 0b059d7ffc6bb557cf7f49496862faa1d36bfa51
1 change: 1 addition & 0 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -95,6 +95,7 @@ jobs:
run: |
sudo apt update
sudo apt install libpulse-dev libegl1-mesa libopengl0 gstreamer1.0-gl
- uses: tlambert03/setup-qt-libs@v1
- name: Install Conda
uses: conda-incubator/setup-miniconda@v2
with:
Expand Down
3 changes: 0 additions & 3 deletions qtpy/tests/test_qtcore.py
Original file line number Diff line number Diff line change
Expand Up @@ -53,9 +53,6 @@ def test_QTime_toPython_and_toPyTime(method):
assert py_time == NOW.time()


@pytest.mark.skipif(
sys.platform.startswith('linux') and not_using_conda(),
reason="Fatal Python error: Aborted on Linux CI when not using conda")
def test_qeventloop_exec_(qtbot):
"""Test QEventLoop.exec_"""
assert QtCore.QEventLoop.exec_ is not None
Expand Down
15 changes: 0 additions & 15 deletions qtpy/tests/test_qtgui.py
Original file line number Diff line number Diff line change
Expand Up @@ -8,9 +8,6 @@
from qtpy.tests.utils import not_using_conda


@pytest.mark.skipif(
sys.platform.startswith('linux') and not_using_conda(),
reason="Fatal Python error: Aborted on Linux CI when not using conda")
def test_qfontmetrics_width(qtbot):
"""Test QFontMetrics and QFontMetricsF width"""
assert QtGui.QFontMetrics.width is not None
Expand All @@ -24,19 +21,13 @@ def test_qfontmetrics_width(qtbot):
assert 39 <= widthF <= 63


@pytest.mark.skipif(
sys.platform.startswith('linux') and not_using_conda(),
reason="Fatal Python error: Aborted on Linux CI when not using conda")
def test_qdrag_functions(qtbot):
"""Test functions mapping for QtGui.QDrag."""
assert QtGui.QDrag.exec_ is not None
drag = QtGui.QDrag(None)
drag.exec_()


@pytest.mark.skipif(
sys.platform.startswith('linux') and not_using_conda(),
reason="Fatal Python error: Aborted on Linux CI when not using conda")
def test_QGuiApplication_exec_():
"""Test `QtGui.QGuiApplication.exec_`"""
assert QtGui.QGuiApplication.exec_ is not None
Expand All @@ -59,9 +50,6 @@ def test_what_moved_to_qtgui_in_qt6():
assert QtGui.QUndoCommand is not None


@pytest.mark.skipif(
sys.platform.startswith('linux') and not_using_conda(),
reason="Segmentation fault/Aborted on Linux CI when not using conda")
def test_qtextdocument_functions(pdf_writer):
"""Test functions mapping for QtGui.QTextDocument."""
assert QtGui.QTextDocument.print_ is not None
Expand All @@ -82,9 +70,6 @@ def test_enum_access():
assert QtGui.QImage.Format_Invalid == QtGui.QImage.Format.Format_Invalid


@pytest.mark.skipif(
sys.platform.startswith('linux') and not_using_conda(),
reason="Fatal Python error: Aborted on Linux CI when not using conda")
@pytest.mark.skipif(
sys.platform == 'darwin' and sys.version_info[:2] == (3, 7),
reason="Stalls on macOS CI with Python 3.7")
Expand Down
5 changes: 0 additions & 5 deletions qtpy/tests/test_qtprintsupport.py
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,6 @@
import pytest

from qtpy import QtPrintSupport
from qtpy.tests.utils import not_using_conda


def test_qtprintsupport():
Expand All @@ -30,10 +29,6 @@ def test_qprintdialog_exec_():
assert QtPrintSupport.QPrintDialog.exec_ is not None


@pytest.mark.skipif(
sys.platform.startswith("linux") and not_using_conda(),
reason="Fatal Python error: Aborted on Linux CI when not using conda",
)
def test_qprintpreviewwidget_print_(qtbot):
"""Test qtpy.QtPrintSupport.QPrintPreviewWidget print_"""
assert QtPrintSupport.QPrintPreviewWidget.print_ is not None
Expand Down
19 changes: 0 additions & 19 deletions qtpy/tests/test_qtwidgets.py
Original file line number Diff line number Diff line change
Expand Up @@ -4,12 +4,8 @@
import pytest

from qtpy import PYQT5, PYQT_VERSION, QtCore, QtGui, QtWidgets
from qtpy.tests.utils import using_conda, not_using_conda


@pytest.mark.skipif(
sys.platform.startswith('linux') and not_using_conda(),
reason="Fatal Python error: Aborted on Linux CI when not using conda")
def test_qtextedit_functions(qtbot, pdf_writer):
"""Test functions mapping for QtWidgets.QTextEdit."""
assert QtWidgets.QTextEdit.setTabStopWidth
Expand Down Expand Up @@ -37,9 +33,6 @@ def test_what_moved_to_qtgui_in_qt6():
assert QtWidgets.QUndoCommand is not None


@pytest.mark.skipif(
sys.platform.startswith('linux') and not_using_conda(),
reason="Fatal Python error: Aborted on Linux CI when not using conda")
def test_qplaintextedit_functions(qtbot, pdf_writer):
"""Test functions mapping for QtWidgets.QPlainTextEdit."""
assert QtWidgets.QPlainTextEdit.setTabStopWidth
Expand All @@ -53,9 +46,6 @@ def test_qplaintextedit_functions(qtbot, pdf_writer):
assert output_path.exists()


@pytest.mark.skipif(
sys.platform.startswith('linux') and not_using_conda(),
reason="Fatal Python error: Aborted on Linux CI when not using conda")
def test_QApplication_exec_():
"""Test `QtWidgets.QApplication.exec_`"""
assert QtWidgets.QApplication.exec_ is not None
Expand All @@ -69,9 +59,6 @@ def test_QApplication_exec_():
app.exec_()


@pytest.mark.skipif(
sys.platform.startswith('linux') and not_using_conda(),
reason="Fatal Python error: Aborted on Linux CI when not using conda")
@pytest.mark.skipif(
sys.platform == 'darwin' and sys.version_info[:2] == (3, 7),
reason="Stalls on macOS CI with Python 3.7")
Expand All @@ -83,9 +70,6 @@ def test_qdialog_functions(qtbot):
dialog.exec_()


@pytest.mark.skipif(
sys.platform.startswith('linux') and not_using_conda(),
reason="Fatal Python error: Aborted on Linux CI when not using conda")
@pytest.mark.skipif(
sys.platform == 'darwin' and sys.version_info[:2] == (3, 7),
reason="Stalls on macOS CI with Python 3.7")
Expand All @@ -102,9 +86,6 @@ def __init__(self):
dialog.exec_()


@pytest.mark.skipif(
sys.platform.startswith('linux') and not_using_conda(),
reason="Fatal Python error: Aborted on Linux CI when not using conda")
@pytest.mark.skipif(
sys.platform == 'darwin' and sys.version_info[:2] == (3, 7),
reason="Stalls on macOS CI with Python 3.7")
Expand Down
10 changes: 0 additions & 10 deletions qtpy/tests/test_uic.py
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,6 @@
pytest.importorskip("pyside2uic", reason="pyside2uic not installed")

from qtpy import uic
from qtpy.tests.utils import not_using_conda


QCOMBOBOX_SUBCLASS = """
Expand Down Expand Up @@ -42,9 +41,6 @@ def enabled_qcombobox_subclass(temp_dir_path):
sys.path.pop(0)


@pytest.mark.skipif(
sys.platform.startswith('linux') and not_using_conda(),
reason="Segfaults on Linux when not using conda under all bindings (PYSIDE2/6 & PYQT5/6)")
def test_load_ui(qtbot):
"""
Make sure that the patched loadUi function behaves as expected with a
Expand All @@ -62,9 +58,6 @@ def test_load_ui(qtbot):
@pytest.mark.skipif(
PYSIDE2 or PYSIDE6,
reason="PySide2uic not consistently installed across platforms/versions")
@pytest.mark.skipif(
sys.platform.startswith('linux') and not_using_conda(),
reason="Segfaults on Linux when not using conda under all bindings (PYSIDE2/6 & PYQT5/6)")
def test_load_ui_type(qtbot):
"""
Make sure that the patched loadUiType function behaves as expected with a
Expand All @@ -88,9 +81,6 @@ def __init__(self):
assert isinstance(ui.comboBox, QComboBox)


@pytest.mark.skipif(
sys.platform.startswith('linux') and not_using_conda(),
reason="Segfaults on Linux when not using conda under all bindings (PYSIDE2/6 & PYQT5/6)")
def test_load_ui_custom_auto(qtbot, tmp_path):
"""
Test that we can load a .ui file with custom widgets without having to
Expand Down