Skip to content
Snippets Groups Projects
Commit 6de5e887 authored by Florian Thöni's avatar Florian Thöni
Browse files

Clean helpers

parent 30d0633a
No related branches found
No related tags found
No related merge requests found
......@@ -5,7 +5,7 @@ from PyQt5.QtCore import Qt
from PyQt5.QtTest import QTest
from sakia.data.processors import ConnectionsProcessor, BlockchainProcessor
from sakia.gui.dialogs.connection_cfg import ConnectionConfigController
from tests.helpers import click_on_top_message_box, select_file_dialog, accept_dialog
from tests.helpers import select_file_dialog, accept_dialog
def assert_key_parameters_behaviour(connection_config_dialog, user):
......
......@@ -16,22 +16,6 @@ def accept_dialog(title):
if isinstance(w, QDialog) and w.windowTitle() == title:
w.accept()
def click_on_top_message_box():
topWidgets = QApplication.topLevelWidgets()
for w in topWidgets:
if isinstance(w, QMessageBox):
QTest.keyClick(w, Qt.Key_Enter)
elif isinstance(w, QDialog) and w.windowTitle() == "Registration":
QTest.keyClick(w, Qt.Key_Enter)
def yes_on_top_message_box():
topWidgets = QApplication.topLevelWidgets()
for w in topWidgets:
if isinstance(w, QMessageBox):
QTest.mouseClick(w.button(QMessageBox.Yes), Qt.LeftButton)
def select_file_dialog(filename):
topWidgets = QApplication.topLevelWidgets()
for w in topWidgets:
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment