fix(@test): linux test run

This commit is contained in:
Anthony Laibe 2022-07-13 15:14:52 +02:00 committed by Anthony Laibe
parent 48229e94c8
commit 5c53cca9f8
6 changed files with 16 additions and 14 deletions

5
.gitignore vendored
View File

@ -34,6 +34,11 @@ notarization.log
status-desktop.log status-desktop.log
nim_status_client.log nim_status_client.log
# Squish test ================================================================
test/ui-test/testSuites/suite_status/config.xml
test/ui-test/testSuites/suite_status/envvars
# CPP app ===================================================================== # CPP app =====================================================================

View File

@ -9,6 +9,7 @@
# *****************************************************************************/ # *****************************************************************************/
from enum import Enum from enum import Enum
import sys
from drivers.SquishDriver import * from drivers.SquishDriver import *
from drivers.SquishDriverVerification import * from drivers.SquishDriverVerification import *
@ -84,7 +85,8 @@ class StatusWelcomeScreen:
self.input_password(password) self.input_password(password)
click_obj_by_name(SignUpComponents.FINALIZE_PASSWORD_STEP.value) click_obj_by_name(SignUpComponents.FINALIZE_PASSWORD_STEP.value)
click_obj_by_name(SignUpComponents.PASSWORD_PREFERENCE.value) if sys.platform == "darwin":
click_obj_by_name(SignUpComponents.PASSWORD_PREFERENCE.value)
def input_username(self, username: str): def input_username(self, username: str):
type(SignUpComponents.USERNAME_INPUT.value, username) type(SignUpComponents.USERNAME_INPUT.value, username)
@ -99,7 +101,9 @@ class StatusWelcomeScreen:
click_obj_by_name(SignUpComponents.CREATE_PASSWORD.value) click_obj_by_name(SignUpComponents.CREATE_PASSWORD.value)
def _agree_terms_and_conditions(self): def _agree_terms_and_conditions(self):
click_obj_by_name(AgreementPopUp.OK_GOT_IT_BUTTON.value) if sys.platform == "darwin":
click_obj_by_name(AgreementPopUp.OK_GOT_IT_BUTTON.value)
click_obj_by_name(AgreementPopUp.ACKNOWLEDGE_CHECKBOX.value) click_obj_by_name(AgreementPopUp.ACKNOWLEDGE_CHECKBOX.value)
check_obj_by_name(AgreementPopUp.TERMS_OF_USE_CHECK_BOX.value) check_obj_by_name(AgreementPopUp.TERMS_OF_USE_CHECK_BOX.value)
click_obj_by_name(AgreementPopUp.GET_STARTED_BUTTON.value) click_obj_by_name(AgreementPopUp.GET_STARTED_BUTTON.value)

View File

@ -1,8 +0,0 @@
<testconfig version="1.0">
<information>
<summary/>
<description/>
</information>
<testsettings/>
<passwords/>
</testconfig>

View File

@ -1,11 +1,11 @@
# -*- coding: utf-8 -*- # -*- coding: utf-8 -*-
# This file contains hook functions to run as the .feature file is executed. # This file contains hook functions to run as the .feature file is executed.
sys.path.append(os.path.join(os.path.dirname(__file__), "../../../src/"))
from utils.FileManager import * from utils.FileManager import *
sys.path.append(os.path.join(os.path.dirname(__file__), "../../../src/"))
_statusDektopAppName = "nim_status_client" _statusDektopAppName = "nim_status_client"
_appClosureTimeout = 2 #[seconds] _appClosureTimeout = 2 #[seconds]

View File

@ -14,11 +14,12 @@
# * with a pattern which is matched against the steps being executed. # * with a pattern which is matched against the steps being executed.
# ***************************************************************************** # *****************************************************************************
from common.Common import * from common.Common import *
import time
@When("the user restarts the app") @When("the user restarts the app")
def step(context): def step(context):
waitFor(lambda: currentApplicationContext().detach(), 100) waitFor(lambda: currentApplicationContext().detach(), 500)
time.sleep(5)
startApplication("nim_status_client") startApplication("nim_status_client")