Skip to content

Commit c6b7437

Browse files
afterEachScenario flag - HyperExecute
1 parent 1cbccb0 commit c6b7437

File tree

2 files changed

+13
-0
lines changed

2 files changed

+13
-0
lines changed

docs/deep-dive-into-hyperexecute-yaml.md

Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1302,6 +1302,18 @@ We can choose to run on local/remote(on HYP Vms) from the location command. Type
13021302

13031303
***
13041304

1305+
### `afterEachScenario`
1306+
The `afterEachScenario` flag is used to define tasks that should be executed after each test scenario. This can be particularly useful for cleanup activities, such as clearing cookies, resetting databases, or capturing logs, ensuring that each test scenario starts with a clean state. This flag allows you to specify a list of commands or scripts that will run sequentially after the completion of each scenario. This ensures that any necessary teardown steps are consistently applied, maintaining the integrity and isolation of your test scenarios.
1307+
1308+
```yaml
1309+
afterEachScenario:
1310+
- echo "Running a script"
1311+
- pwsh run.test
1312+
- bash script.sh
1313+
```
1314+
1315+
***
1316+
13051317
### `buildConfig`
13061318

13071319
This is used to manage hyperlink behavior based on test status. Here's a breakdown of the parameters within buildConfig:

docs/hyperexecute-yaml-parameters.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -163,6 +163,7 @@ The **HyperExecute YAML** file serves as the foundational component for test exe
163163
| [afterAll](/support/docs/deep-dive-into-hyperexecute-yaml/#afterall) | Map |It is used to run commands after the job has finished. |
164164
| [project](/support/docs/deep-dive-into-hyperexecute-yaml/#project) | String | Segregate data at a project/repo level |
165165
| [slackChannel](/support/docs/deep-dive-into-hyperexecute-yaml/#slackchannel) | String | Allows you to receive notifications of your Job updates directly in your preferred Slack channel. |
166+
| [afterEachScenario](/support/docs/deep-dive-into-hyperexecute-yaml/#aftereachscenario) | | |
166167

167168
<nav aria-label="breadcrumbs">
168169
<ul className="breadcrumbs">

0 commit comments

Comments
 (0)