Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/owncloud/client.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
path: root/test
diff options
context:
space:
mode:
authorswoichha <swoichhaa@gmail.com>2021-04-15 11:05:44 +0300
committerArtur Neumann <artur@jankaritech.com>2021-04-15 14:23:09 +0300
commit089c037a2f7a19c0a01ab0e58aa26bfeb0fa85f9 (patch)
tree4e6460d20d448e06132d5bb2602f13740ad4c336 /test
parentda480617d6b9b5f89c88836c60c5ad2d0caa8359 (diff)
add new step for polling interval
Diffstat (limited to 'test')
-rw-r--r--test/gui/shared/steps/steps.py18
-rw-r--r--test/gui/tst_sharing/test.feature6
-rw-r--r--test/gui/tst_syncing/test.feature18
3 files changed, 14 insertions, 28 deletions
diff --git a/test/gui/shared/steps/steps.py b/test/gui/shared/steps/steps.py
index d46f996c7..c548703be 100644
--- a/test/gui/shared/steps/steps.py
+++ b/test/gui/shared/steps/steps.py
@@ -48,7 +48,7 @@ def step(context, displayname, host):
), displayname + "\n" + host
)
-def setUpClient(context, username, password, configContent):
+def setUpClient(context, username, password, pollingInterval):
userSetting = '''
[Accounts]
0/Folders/1/ignoreHiddenFiles=true
@@ -67,7 +67,7 @@ def setUpClient(context, username, password, configContent):
version=2
'''
userFirstName = username.split()
- userSetting = userSetting + configContent
+ userSetting = userSetting + pollingInterval
args = {'displayUserName': username,
'davUserName': username.lower(),
'displayUserFirstName': userFirstName[0],
@@ -87,13 +87,15 @@ def setUpClient(context, username, password, configContent):
clickButton(waitForObject(names.enter_Password_OK_QPushButton))
except LookupError:
pass
-
-@Given('user "|any|" has set up a client with these settings and password |any|:')
+
+@Given('user "|any|" has set up a client with poll interval settings and password "|any|"')
def step(context, username, password):
- configContent = "\n".join(context.multiLineText)
- setUpClient(context, username, password, configContent)
-
-@Given('user "|any|" has set up a client with default settings and password |any|')
+ pollingInterval='''[ownCloud]
+ remotePollInterval=5000
+ '''
+ setUpClient(context, username, password, pollingInterval)
+
+@Given('user "|any|" has set up a client with default settings and password "|any|"')
def step(context, username, password):
setUpClient(context, username, password,'')
diff --git a/test/gui/tst_sharing/test.feature b/test/gui/tst_sharing/test.feature
index 996a557fa..813fe8385 100644
--- a/test/gui/tst_sharing/test.feature
+++ b/test/gui/tst_sharing/test.feature
@@ -30,11 +30,7 @@ Feature: Sharing
And user "Alice" has shared folder "simple-folder" on the server with user "Brian"
And user "Brian" has accepted the share "simple-folder" on the server offered by user "Alice"
And user "Brian" has shared folder "Shares/simple-folder" on the server with user "Carol"
- And user "Brian" has set up a client with these settings and password "AaBb2Cc3Dd4":
- """
- [ownCloud]
- remotePollInterval=5000
- """
+ And user "Brian" has set up a client with poll interval settings and password "AaBb2Cc3Dd4"
And user "Alice" has updated the share permissions on the server for folder "/simple-folder" to "read" for user "Brian"
When user "Brian" opens the sharing dialog of "%client_sync_path%/Shares/simple-folder" using the client-UI
Then the error text "The file can not be shared because it was shared without sharing permission." should be displayed in the sharing dialog
diff --git a/test/gui/tst_syncing/test.feature b/test/gui/tst_syncing/test.feature
index 8b13edf6f..bd8125bea 100644
--- a/test/gui/tst_syncing/test.feature
+++ b/test/gui/tst_syncing/test.feature
@@ -6,11 +6,7 @@ Feature: Syncing files
Scenario: Syncing a file to the server
Given user "Alice" has been created on the server with default attributes
- And user "Alice" has set up a client with these settings and password "1234":
- """
- [ownCloud]
- remotePollInterval=5000
- """
+ And user "Alice" has set up a client with poll interval settings and password "1234"
When the user creates a file "lorem-for-upload.txt" with the following content on the file system
"""
test content
@@ -20,11 +16,7 @@ Feature: Syncing files
Scenario: Syncing a file from the server
Given user "Alice" has been created on the server with default attributes
- And user "Alice" has set up a client with these settings and password "1234":
- """
- [ownCloud]
- remotePollInterval=5000
- """
+ And user "Alice" has set up a client with poll interval settings and password "1234"
And user "Alice" has uploaded file on the server with content "test content" to "uploaded-lorem.txt"
When the user waits for file "uploaded-lorem.txt" to be synced
Then the file "uploaded-lorem.txt" should exist on the file system with the following content
@@ -34,11 +26,7 @@ Feature: Syncing files
Scenario: Syncing a file from the server and creating a conflict
Given user "Alice" has been created on the server with default attributes
- And user "Alice" has set up a client with these settings and password "1234":
- """
- [ownCloud]
- remotePollInterval=5000
- """
+ And user "Alice" has set up a client with poll interval settings and password "1234"
And user "Alice" has uploaded file on the server with content "test content" to "uploaded-lorem.txt"
And the user has waited for file "conflict.txt" to be synced
And the user has paused the file sync