Skip to content

Commit edcd4f1

Browse files
committed
Fixed QDialog.Accepted compat. issue with PySide6
1 parent da95579 commit edcd4f1

File tree

2 files changed

+3
-2
lines changed

2 files changed

+3
-2
lines changed

plotpy/tests/gui/test_fliprotate.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -54,7 +54,7 @@ def dialog_test(fname):
5454
dlg.toolbar.addWidget(rot_point_btn)
5555

5656
dlg.transform.set_item(item)
57-
if exec_dialog(dlg) == dlg.Accepted:
57+
if exec_dialog(dlg) == QW.QDialog.Accepted:
5858
array1 = dlg.transform.get_result()
5959
dlg1 = imshow(array0, title="array0")
6060
dlg2 = imshow(array1, title="array1")

plotpy/tests/gui/test_rotatecrop.py

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -12,6 +12,7 @@
1212
import numpy as np
1313
from guidata.env import execenv
1414
from guidata.qthelpers import exec_dialog, qt_app_context
15+
from qtpy import QtWidgets as QW
1516

1617
from plotpy import io
1718
from plotpy.builder import make
@@ -69,7 +70,7 @@ def dialog_test(fname="brain.png"):
6970
array0, item = create_test_data(fname)
7071
dlg = RotateCropDialog(None)
7172
dlg.transform.set_item(item)
72-
if exec_dialog(dlg) == dlg.Accepted:
73+
if exec_dialog(dlg) == QW.QDialog.Accepted:
7374
array1 = dlg.transform.get_result()
7475
if array0.shape == array1.shape:
7576
assert (array1 == array0).all()

0 commit comments

Comments
 (0)