source: sasview/src/sas/qtgui/UnitTesting/SquishTestSuites/suite_sasview_bdd/shared/scripts/bdd_hooks.py

ESS_GUI
Last change on this file was d6b234b, checked in by Piotr Rozyczko <rozyczko@…>, 7 years ago

Cleanup after merge (removed sasview/sasview)

  • Property mode set to 100755
File size: 683 bytes
Line 
1# -*- coding: utf-8 -*-
2
3# This file contains hook functions to run as the .feature file is executed.
4#
5# A common use-case is to use the OnScenarioStart/OnScenarioEnd hooks to
6# start and stop an AUT, e.g.
7#
8# @OnScenarioStart
9# def hook(context):
10#     startApplication("addressbook")
11#
12# @OnScenarioEnd
13# def hook(context):
14#     currentApplicationContext().detach()
15#
16# See the section 'Performing Actions During Test Execution Via Hooks' in the Squish
17# manual for a complete reference of the available API.
18
19# Detach (i.e. potentially terminate) all AUTs at the end of a scenario
20@OnScenarioEnd
21def hook(context):
22    for ctx in applicationContextList():
23        ctx.detach()
24
Note: See TracBrowser for help on using the repository browser.