2022-05-26 15:00:00 +00:00
|
|
|
# -*- coding: utf-8 -*-
|
|
|
|
|
2022-06-07 23:44:48 +00:00
|
|
|
# ******************************************************************************
|
2022-05-26 15:00:00 +00:00
|
|
|
# Status.im
|
2022-06-07 23:44:48 +00:00
|
|
|
# *****************************************************************************/
|
2022-05-26 15:00:00 +00:00
|
|
|
# /**
|
|
|
|
# * \file steps.py
|
|
|
|
# *
|
|
|
|
# * \test Status Desktop - Login
|
|
|
|
# * \date February 2022
|
|
|
|
# * \brief This file contains snippets of script code to be executed as the .feature
|
|
|
|
# * file is processed.
|
|
|
|
# * The decorators Given/When/Then/Step can be used to associate a script snippet
|
|
|
|
# * with a pattern which is matched against the steps being executed.
|
|
|
|
# *****************************************************************************
|
|
|
|
from common.Common import *
|
|
|
|
|
2022-06-07 23:44:48 +00:00
|
|
|
|
2022-06-16 01:46:45 +00:00
|
|
|
@When("the user restarts the app")
|
2022-05-26 15:00:00 +00:00
|
|
|
def step(context):
|
2022-06-16 01:46:45 +00:00
|
|
|
waitFor(lambda: currentApplicationContext().detach(), 100)
|
2022-05-26 15:00:00 +00:00
|
|
|
startApplication("nim_status_client")
|
2022-06-07 23:44:48 +00:00
|
|
|
|
|
|
|
|
2022-06-01 02:43:53 +00:00
|
|
|
@When("user inputs the following |any| with ui-component |any|")
|
2022-05-26 15:00:00 +00:00
|
|
|
def step(context, text, obj):
|
|
|
|
input_text(text, obj)
|
2022-06-07 23:44:48 +00:00
|
|
|
|
2022-06-01 02:43:53 +00:00
|
|
|
|
|
|
|
@When("user clicks on the following ui-component |any|")
|
|
|
|
def step(context, obj):
|
|
|
|
click_on_an_object(obj)
|
2022-05-26 15:00:00 +00:00
|
|
|
|
|
|
|
|
2022-06-01 02:43:53 +00:00
|
|
|
@Then("the following ui-component |any| is not enabled")
|
2022-05-26 15:00:00 +00:00
|
|
|
def step(context, obj):
|
|
|
|
object_not_enabled(obj)
|