status-desktop/test/ui-test/testSuites/suite_status/shared/scripts/bdd_hooks.py

25 lines
601 B
Python
Raw Normal View History

# -*- coding: utf-8 -*-
# This file contains hook functions to run as the .feature file is executed.
2022-07-13 13:14:52 +00:00
sys.path.append(os.path.join(os.path.dirname(__file__), "../../../src/"))
2022-07-13 13:14:52 +00:00
from utils.FileManager import *
_statusDektopAppName = "nim_status_client"
_appClosureTimeout = 2 #[seconds]
@OnScenarioStart
def hook(context):
erase_directory("../../../../../Status/data")
erase_directory("../../../../../Status/qt")
startApplication(_statusDektopAppName)
context.userData = {}
@OnScenarioEnd
def hook(context):
currentApplicationContext().detach()
snooze(_appClosureTimeout)