Skip to content

TST/MNT: in pyside6 designer is named 'pyside6-designer', also disable designer plugin test on pyside6 #1183

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

Draft
wants to merge 1 commit into
base: master
Choose a base branch
from
Draft
Show file tree
Hide file tree
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
7 changes: 5 additions & 2 deletions pydm/main_window.py
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
from qtpy.QtWidgets import QApplication, QMainWindow, QFileDialog, QAction, QMessageBox
from qtpy.QtCore import Qt, QTimer, Slot, QSize, QLibraryInfo, QCoreApplication
from qtpy.QtGui import QKeySequence
from .utilities import IconFont, find_file, establish_widget_connections, close_widget_connections
from .utilities import IconFont, find_file, establish_widget_connections, close_widget_connections, ACTIVE_QT_WRAPPER, QtWrapperTypes
from .pydm_ui import Ui_MainWindow
from .display import Display, ScreenTarget, load_file, clear_compiled_ui_file_cache
from .connection_inspector import ConnectionInspector
Expand Down Expand Up @@ -111,11 +111,14 @@ def __init__(
QLibraryInfo.location(QLibraryInfo.BinariesPath),
QLibraryInfo.location(QLibraryInfo.LibraryExecutablesPath),
)

# look into mac and windows naming later
executable_name = "designer" if ACTIVE_QT_WRAPPER == QtWrapperTypes.PYQT5 else "pyside6-designer"
for bin_path in possible_designer_bin_paths:
if platform.system() == "Darwin":
designer_path = os.path.join(bin_path, "Designer.app/Contents/MacOS/Designer")
elif platform.system() == "Linux":
designer_path = os.path.join(bin_path, "designer")
designer_path = os.path.join(bin_path, executable_name)
else:
designer_path = os.path.join(bin_path, "designer.exe")
if os.path.isfile(designer_path):
Expand Down
6 changes: 5 additions & 1 deletion pydm/tests/test_plugins_import.py
Original file line number Diff line number Diff line change
@@ -1,5 +1,9 @@
from ..widgets.qtplugin_base import qtplugin_factory
import pytest
from ..utilities import ACTIVE_QT_WRAPPER, QtWrapperTypes
if ACTIVE_QT_WRAPPER == QtWrapperTypes.PYSIDE6:
pytest.skip("pydm with pyside6 does not support custom pydm-widgets yet in pyside6-designer!", allow_module_level=True)

from ..widgets.qtplugin_base import qtplugin_factory

def test_import_byte_plugin():
# Byte plugin
Expand Down
Loading