diff --git a/test/gui/shared/scripts/names.py b/test/gui/shared/scripts/names.py index 01df761a5da..34e9f78c45f 100644 --- a/test/gui/shared/scripts/names.py +++ b/test/gui/shared/scripts/names.py @@ -98,4 +98,5 @@ o_tableView_0_1_QModelIndex = {"column": 1, "container": oCC_IssuesWidget_tableView_QTableView, "row": 0, "type": "QModelIndex"} settings_settingsdialog_toolbutton_Add_account_QToolButton = {"name": "settingsdialog_toolbutton_Add account", "type": "QToolButton", "visible": 1, "window": settings_OCC_SettingsDialog} settings_settingsdialog_toolbutton_Activity_QToolButton = {"name": "settingsdialog_toolbutton_Activity", "type": "QToolButton", "visible": 1, "window": settings_OCC_SettingsDialog} -sharingDialog_Close_QPushButton = {"text": "Close", "type": "QPushButton", "unnamed": 1, "visible": 1, "window": sharingDialog_OCC_ShareDialog} \ No newline at end of file +sharingDialog_Close_QPushButton = {"text": "Close", "type": "QPushButton", "unnamed": 1, "visible": 1, "window": sharingDialog_OCC_ShareDialog} +stack_Enable_experimental_placeholder_mode_QPushButton = {"container": settings_stack_QStackedWidget, "text": "Enable experimental placeholder mode", "type": "QPushButton", "unnamed": 1, "visible": 1} diff --git a/test/gui/shared/steps/steps.py b/test/gui/shared/steps/steps.py index 6225070502d..de1d7cc46a8 100644 --- a/test/gui/shared/steps/steps.py +++ b/test/gui/shared/steps/steps.py @@ -724,3 +724,15 @@ def step(context, resource, group): sharingDialog = SharingDialog() sharingDialog.selectCollaborator(group, True) + + +@When("the user enables virtual file support") +def step(context): + mouseClick(waitForObjectItem(names.stack_folderList_QTreeView, "_1"), 718, 27, Qt.NoModifier, Qt.LeftButton) + activateItem(waitForObjectItem(names.settings_QMenu, "Enable virtual file support (experimental)...")) + clickButton(waitForObject(names.stack_Enable_experimental_placeholder_mode_QPushButton)) + + +@Then("the virtual file support should be enabled") +def step(context): + pass diff --git a/test/gui/suite.conf b/test/gui/suite.conf index cbb183980ee..fd4cbf70171 100644 --- a/test/gui/suite.conf +++ b/test/gui/suite.conf @@ -4,6 +4,6 @@ HOOK_SUB_PROCESSES=false IMPLICITAUTSTART=0 LANGUAGE=Python OBJECTMAPSTYLE=script -TEST_CASES=tst_addAccount tst_sharing tst_syncing tst_loginLogout tst_removeAccountConnection tst_checkAlltabs +TEST_CASES=tst_addAccount tst_sharing tst_syncing tst_loginLogout tst_removeAccountConnection tst_checkAlltabs tst_vfs VERSION=3 WRAPPERS=Qt diff --git a/test/gui/tst_vfs/test.feature b/test/gui/tst_vfs/test.feature new file mode 100644 index 00000000000..32cd65510a8 --- /dev/null +++ b/test/gui/tst_vfs/test.feature @@ -0,0 +1,12 @@ +Feature: Enable/disable virtual file support + + As a user + I want to enable virtual file support + So that I can synchronize virtual files with local folder + + + Scenario: Enable VFS + Given user "Alice" has been created on the server with default attributes and without skeleton files + And user "Alice" has set up a client with default settings + When the user enables virtual file support + Then the virtual file support should be enabled \ No newline at end of file diff --git a/test/gui/tst_vfs/test.py b/test/gui/tst_vfs/test.py new file mode 100644 index 00000000000..75e47d0b334 --- /dev/null +++ b/test/gui/tst_vfs/test.py @@ -0,0 +1,8 @@ +source(findFile('scripts', 'python/bdd.py')) + +setupHooks('../shared/scripts/bdd_hooks.py') +collectStepDefinitions('./steps', '../shared/steps') + +def main(): + testSettings.throwOnFailure = True + runFeatureFile('test.feature')