Skip to content

TST: make timeplot testcase work for pyside6 too #1229

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 1 commit into from
Apr 25, 2025
Merged
Changes from all commits
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
11 changes: 7 additions & 4 deletions pydm/tests/widgets/test_timeplot.py
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@
from unittest import mock
from ...widgets.channel import PyDMChannel
from ...widgets.timeplot import TimePlotCurveItem, PyDMTimePlot, TimeAxisItem, MINIMUM_BUFFER_SIZE, DEFAULT_BUFFER_SIZE
from ...utilities import remove_protocol
from ...utilities import remove_protocol, ACTIVE_QT_WRAPPER, QtWrapperTypes
from qtpy.QtTest import QSignalSpy
from unittest.mock import MagicMock

Expand Down Expand Up @@ -44,9 +44,12 @@ def test_timeplotcurveitem_severityChanged_updates_attributes_and_emits(timeplot
assert timeplotcurveitem_widget.severity_raw == 2
assert timeplotcurveitem_widget.severity == "MAJOR"

assert len(severity_spy) == 1
assert severity_spy[0] == [2]

if ACTIVE_QT_WRAPPER == QtWrapperTypes.PYQT5:
assert len(severity_spy) == 1
assert severity_spy[0] == [2]
else:
assert severity_spy.count() == 1
assert severity_spy.at(0) == [2]

def test_timeplotcurveitem_alarm_severity_changed_valid_values(timeplotcurveitem_widget):
"""
Expand Down