Skip to content

Commit 74923ee

Browse files
amanchopra1905Ishavyas9
authored andcommitted
afterEachScenario flag - HyperExecute
1 parent 3c02e66 commit 74923ee

File tree

2 files changed

+15
-1
lines changed

2 files changed

+15
-1
lines changed

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

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

12731273
***
12741274

1275+
### `afterEachScenario`
1276+
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.
1277+
1278+
```yaml
1279+
afterEachScenario:
1280+
- echo "Running a script"
1281+
- pwsh run.test
1282+
- bash script.sh
1283+
```
1284+
1285+
***
1286+
12751287
### `buildConfig`
12761288

12771289
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: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -161,7 +161,9 @@ The **HyperExecute YAML** file serves as the foundational component for test exe
161161
| [alwaysRunPostSteps](/support/docs/deep-dive-into-hyperexecute-yaml/#alwaysrunpoststeps) | Boolean | Execute the Post Steps in every scenario case |
162162
| [cacheTestURL](/support/docs/deep-dive-into-hyperexecute-yaml/#cachetesturl) | Boolean |It enables users to cache static test files. |
163163
| [afterAll](/support/docs/deep-dive-into-hyperexecute-yaml/#afterall) | Map |It is used to run commands after the job has finished. |
164-
| [projectName](/support/docs/deep-dive-into-hyperexecute-yaml/#projectname) | String | Segregate data at a project/repo level |
164+
| [project](/support/docs/deep-dive-into-hyperexecute-yaml/#project) | String | Segregate data at a project/repo level |
165+
| [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) | | |
165167

166168
<nav aria-label="breadcrumbs">
167169
<ul className="breadcrumbs">

0 commit comments

Comments
 (0)