diff --git a/tests/system/shared/utils.py b/tests/system/shared/utils.py index b331ddb6671..e9209177eb8 100644 --- a/tests/system/shared/utils.py +++ b/tests/system/shared/utils.py @@ -544,13 +544,24 @@ def iterateKits(keepOptionsOpen=False, alreadyOnOptionsDialog=False, else: return result -# set "Always Start Full Help" in "Tools" -> "Options..." -> "Help" -> "General" -def setAlwaysStartFullHelp(): +# set a help viewer that will always be used, regardless of Creator's width + +class HelpViewer: + HELPMODE, SIDEBYSIDE, EXTERNALWINDOW = range(3) + +def setFixedHelpViewer(helpViewer): invokeMenuItem("Tools", "Options...") waitForObjectItem(":Options_QListView", "Help") clickItem(":Options_QListView", "Help", 5, 5, 0, Qt.LeftButton) clickOnTab(":Options.qt_tabwidget_tabbar_QTabBar", "General") - selectFromCombo(":Startup.contextHelpComboBox_QComboBox", "Always Show in Help Mode") + mode = "Always Show " + if helpViewer == HelpViewer.HELPMODE: + mode += "in Help Mode" + elif helpViewer == HelpViewer.SIDEBYSIDE: + mode += "Side-by-Side" + elif helpViewer == HelpViewer.EXTERNALWINDOW: + mode += "in External Window" + selectFromCombo(":Startup.contextHelpComboBox_QComboBox", mode) clickButton(waitForObject(":Options.OK_QPushButton")) def removePackagingDirectory(projectPath): diff --git a/tests/system/suite_HELP/tst_HELP05/test.py b/tests/system/suite_HELP/tst_HELP05/test.py index 2b84e6d7afc..82d337063e7 100755 --- a/tests/system/suite_HELP/tst_HELP05/test.py +++ b/tests/system/suite_HELP/tst_HELP05/test.py @@ -52,6 +52,7 @@ def main(): for p in Qt5Path.getPaths(Qt5Path.DOCS): qchs.append(os.path.join(p, "qtquick.qch")) addHelpDocumentation(qchs) + setFixedHelpViewer(HelpViewer.SIDEBYSIDE) # create qt quick application createNewQtQuickApplication(tempDir(), "SampleApp") editorArea = waitForObject(":Qt Creator_QmlJSEditor::QmlJSTextEditorWidget") diff --git a/tests/system/suite_WELP/tst_WELP01/test.py b/tests/system/suite_WELP/tst_WELP01/test.py index acbc5bc5cc5..f13a29bcceb 100755 --- a/tests/system/suite_WELP/tst_WELP01/test.py +++ b/tests/system/suite_WELP/tst_WELP01/test.py @@ -79,7 +79,7 @@ def main(): if not startedWithoutPluginError(): return - setAlwaysStartFullHelp() + setFixedHelpViewer(HelpViewer.HELPMODE) addCurrentCreatorDocumentation() buttonsAndState = {'Projects':True, 'Examples':False, 'Tutorials':False} diff --git a/tests/system/suite_WELP/tst_WELP03/test.py b/tests/system/suite_WELP/tst_WELP03/test.py index 8b211d606df..3347f34f373 100644 --- a/tests/system/suite_WELP/tst_WELP03/test.py +++ b/tests/system/suite_WELP/tst_WELP03/test.py @@ -66,7 +66,7 @@ def main(): for p in Qt5Path.getPaths(Qt5Path.DOCS): qchs.extend([os.path.join(p, "qtopengl.qch"), os.path.join(p, "qtwidgets.qch")]) addHelpDocumentation(qchs) - setAlwaysStartFullHelp() + setFixedHelpViewer(HelpViewer.HELPMODE) wsButtonFrame, wsButtonLabel = getWelcomeScreenSideBarButton('Get Started Now') if not test.verify(all((wsButtonFrame, wsButtonLabel)), "Verifying: Qt Creator displays Welcome Page with Getting Started."):