playwright-qase-reporter 2.1.4 → 2.1.6

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 CHANGED
@@ -1,3 +1,10 @@
1
+ # playwright-qase-reporter@2.1.6
2
+
3
+ ## What's new
4
+
5
+ - Added support for status filter in the test run.
6
+ - Improved error handling.
7
+
1
8
  # playwright-qase-reporter@2.1.4
2
9
 
3
10
  ## What's new
package/dist/reporter.js CHANGED
@@ -316,11 +316,21 @@ class PlaywrightQaseReporter {
316
316
  testCaseMetadata.fields['is_flaky'] = 'true';
317
317
  }
318
318
  const testTitle = this.removeQaseIdsFromTitle(test.title);
319
+ // Convert CompoundError to regular Error for status determination
320
+ let errorForStatus = null;
321
+ if (error) {
322
+ errorForStatus = new Error(error.message || 'Test failed');
323
+ if (error.stacktrace) {
324
+ errorForStatus.stack = error.stacktrace;
325
+ }
326
+ }
327
+ // Determine status based on error type
328
+ const testStatus = (0, qase_javascript_commons_1.determineTestStatus)(errorForStatus, result.status);
319
329
  const testResult = {
320
330
  attachments: testCaseMetadata.attachments,
321
331
  author: null,
322
332
  execution: {
323
- status: PlaywrightQaseReporter.statusMap[result.status],
333
+ status: testStatus,
324
334
  start_time: result.startTime.valueOf() / 1000,
325
335
  end_time: null,
326
336
  duration: result.duration,
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "playwright-qase-reporter",
3
- "version": "2.1.4",
3
+ "version": "2.1.6",
4
4
  "description": "Qase TMS Playwright Reporter",
5
5
  "main": "./dist/index.js",
6
6
  "types": "./dist/index.d.ts",
@@ -44,7 +44,7 @@
44
44
  "license": "Apache-2.0",
45
45
  "dependencies": {
46
46
  "chalk": "^4.1.2",
47
- "qase-javascript-commons": "~2.3.3",
47
+ "qase-javascript-commons": "~2.4.2",
48
48
  "uuid": "^9.0.0"
49
49
  },
50
50
  "peerDependencies": {