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
diff options
context:
space:
mode:
authorArtur Neumann <artur@jankaritech.com>2021-04-26 11:36:11 +0300
committerArtur Neumann <artur@jankaritech.com>2021-05-11 12:03:29 +0300
commit6a6450e41d46cc72ecedbe9e42e74ef4bcb79f3a (patch)
tree5c73e4a935db64f376c7c2c936aaf4565c3eb7a0 /test/gui/shared
parent91029ede26f69b1137ac5a2607bc53f4a6f55015 (diff)
ability to set client log file in GUI tests
Diffstat (limited to 'test/gui/shared')
-rw-r--r--test/gui/shared/scripts/bdd_hooks.py4
-rw-r--r--test/gui/shared/steps/steps.py13
2 files changed, 13 insertions, 4 deletions
diff --git a/test/gui/shared/scripts/bdd_hooks.py b/test/gui/shared/scripts/bdd_hooks.py
index 6823dcd9e..0832e66ae 100644
--- a/test/gui/shared/scripts/bdd_hooks.py
+++ b/test/gui/shared/scripts/bdd_hooks.py
@@ -27,6 +27,7 @@ def hook(context):
'clientSyncPath': os.environ.get('CLIENT_SYNC_PATH', cfg.get('DEFAULT','CLIENT_SYNC_PATH')),
'clientSyncTimeout': os.environ.get('CLIENT_SYNC_TIMEOUT', cfg.get('DEFAULT','CLIENT_SYNC_TIMEOUT')),
'middlewareUrl': os.environ.get('MIDDLEWARE_URL', cfg.get('DEFAULT','MIDDLEWARE_URL')),
+ 'clientConfigFile': os.environ.get('CLIENT_LOG_FILE', cfg.get('DEFAULT','CLIENT_LOG_FILE')),
}
if context.userData['localBackendUrl'] == '':
@@ -46,6 +47,9 @@ def hook(context):
if context.userData['middlewareUrl'] == '':
context.userData['middlewareUrl']='http://localhost:3000/'
+ if context.userData['clientConfigFile'] == '':
+ context.userData['clientConfigFile']='-'
+
@OnScenarioEnd
def hook(context):
# Detach (i.e. potentially terminate) all AUTs at the end of a scenario
diff --git a/test/gui/shared/steps/steps.py b/test/gui/shared/steps/steps.py
index 6b687f83e..c813f8904 100644
--- a/test/gui/shared/steps/steps.py
+++ b/test/gui/shared/steps/steps.py
@@ -72,8 +72,13 @@ def step(context, displayname, host):
), displayname + "\n" + host
)
-def startClient():
- startApplication("owncloud -s --logfile - --language en_US --confdir " + confdir)
+def startClient(context):
+ startApplication(
+ "owncloud -s" +
+ " --logfile " + context.userData['clientConfigFile'] +
+ " --language en_US" +
+ " --confdir " + confdir
+ )
snooze(1)
def setUpClient(context, username, password, pollingInterval):
@@ -107,7 +112,7 @@ def setUpClient(context, username, password, pollingInterval):
configFile.write(userSetting)
configFile.close()
- startClient()
+ startClient(context)
try:
waitForObject(names.enter_Password_Field, 10000)
@@ -138,7 +143,7 @@ def step(context, username, password):
@Given('the user has started the client')
def step(context):
- startClient()
+ startClient(context)
@When('the user adds an account with')
def step(context):