cucumberjs-qase-reporter 2.2.2 → 2.3.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/changelog.md +7 -0
- package/dist/models.d.ts +1 -0
- package/dist/storage.js +9 -0
- package/docs/usage.md +27 -0
- package/package.json +2 -2
package/changelog.md
CHANGED
package/dist/models.d.ts
CHANGED
package/dist/storage.js
CHANGED
|
@@ -12,6 +12,7 @@ const qaseParametersRegExp = /^@[Qq]ase[Pp]arameters=(.+)$/;
|
|
|
12
12
|
const qaseGroupParametersRegExp = /^@[Qq]ase[Gg]roup[Pp]arameters=(.+)$/;
|
|
13
13
|
const qaseSuiteRegExp = /^@[Qq]ase[Ss]uite=(.+)$/;
|
|
14
14
|
const qaseIgnoreRegExp = /^@[Qq]ase[Ii][Gg][Nn][Oo][Rr][Ee]$/;
|
|
15
|
+
const qaseTagsRegExp = /^@[Qq]ase[Tt]ags=(.+)$/;
|
|
15
16
|
class Storage {
|
|
16
17
|
/**
|
|
17
18
|
* @type {NetworkProfiler | null}
|
|
@@ -285,6 +286,7 @@ class Storage {
|
|
|
285
286
|
testops_project_mapping: hasProjectMapping ? metadata.projectMapping : null,
|
|
286
287
|
id: tcs.id,
|
|
287
288
|
title: metadata.title ?? pickle.name,
|
|
289
|
+
tags: metadata.tags,
|
|
288
290
|
};
|
|
289
291
|
return result;
|
|
290
292
|
}
|
|
@@ -364,6 +366,7 @@ class Storage {
|
|
|
364
366
|
parameters: {},
|
|
365
367
|
group_params: {},
|
|
366
368
|
suite: null,
|
|
369
|
+
tags: [],
|
|
367
370
|
};
|
|
368
371
|
for (const tag of tags) {
|
|
369
372
|
if (qaseIdRegExp.test(tag.name)) {
|
|
@@ -416,6 +419,12 @@ class Storage {
|
|
|
416
419
|
metadata.suite = tag.name.replace(/^@[Qq]ase[Ss]uite=/, '');
|
|
417
420
|
continue;
|
|
418
421
|
}
|
|
422
|
+
if (qaseTagsRegExp.test(tag.name)) {
|
|
423
|
+
const value = tag.name.replace(/^@[Qq]ase[Tt]ags=/, '');
|
|
424
|
+
const parsedTags = value.split(',').map(t => t.trim()).filter(t => t.length > 0);
|
|
425
|
+
metadata.tags.push(...parsedTags);
|
|
426
|
+
continue;
|
|
427
|
+
}
|
|
419
428
|
if (qaseIgnoreRegExp.test(tag.name)) {
|
|
420
429
|
metadata.isIgnore = true;
|
|
421
430
|
}
|
package/docs/usage.md
CHANGED
|
@@ -12,6 +12,7 @@ This guide provides comprehensive instructions for integrating Qase with Cucumbe
|
|
|
12
12
|
- [Adding Title](#adding-title)
|
|
13
13
|
- [Adding Fields](#adding-fields)
|
|
14
14
|
- [Adding Suite](#adding-suite)
|
|
15
|
+
- [Tags](#tags)
|
|
15
16
|
- [Ignoring Tests](#ignoring-tests)
|
|
16
17
|
- [Muting Tests](#muting-tests)
|
|
17
18
|
- [Working with Attachments](#working-with-attachments)
|
|
@@ -144,6 +145,32 @@ Feature: User Authentication
|
|
|
144
145
|
|
|
145
146
|
---
|
|
146
147
|
|
|
148
|
+
## Tags
|
|
149
|
+
|
|
150
|
+
Assign tags to scenarios. Tags help categorize and filter tests in Qase.
|
|
151
|
+
|
|
152
|
+
```gherkin
|
|
153
|
+
@QaseID=1
|
|
154
|
+
@QaseTags=smoke,regression
|
|
155
|
+
Scenario: Login test
|
|
156
|
+
Given I am on the login page
|
|
157
|
+
When I enter valid credentials
|
|
158
|
+
Then I should be logged in
|
|
159
|
+
```
|
|
160
|
+
|
|
161
|
+
Multiple `@QaseTags` annotations accumulate:
|
|
162
|
+
|
|
163
|
+
```gherkin
|
|
164
|
+
@QaseTags=smoke
|
|
165
|
+
@QaseTags=regression
|
|
166
|
+
Scenario: Login test
|
|
167
|
+
Given I am on the login page
|
|
168
|
+
When I enter valid credentials
|
|
169
|
+
Then I should be logged in
|
|
170
|
+
```
|
|
171
|
+
|
|
172
|
+
---
|
|
173
|
+
|
|
147
174
|
## Ignoring Tests
|
|
148
175
|
|
|
149
176
|
Exclude a scenario from Qase reporting using the `@QaseIgnore` tag. The scenario still executes, but results are not sent to Qase:
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "cucumberjs-qase-reporter",
|
|
3
|
-
"version": "2.
|
|
3
|
+
"version": "2.3.0",
|
|
4
4
|
"description": "Qase TMS CucumberJS Reporter",
|
|
5
5
|
"homepage": "https://github.com/qase-tms/qase-javascript",
|
|
6
6
|
"main": "./dist/index.js",
|
|
@@ -40,7 +40,7 @@
|
|
|
40
40
|
"license": "Apache-2.0",
|
|
41
41
|
"dependencies": {
|
|
42
42
|
"@cucumber/messages": "^22.0.0",
|
|
43
|
-
"qase-javascript-commons": "~2.
|
|
43
|
+
"qase-javascript-commons": "~2.6.0"
|
|
44
44
|
},
|
|
45
45
|
"peerDependencies": {
|
|
46
46
|
"@cucumber/cucumber": ">=7.0.0"
|