qase-javascript-commons 2.2.4 → 2.2.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 +13 -0
- package/dist/reporters/testops-reporter.js +2 -2
- package/package.json +1 -1
package/changelog.md
CHANGED
|
@@ -1,3 +1,16 @@
|
|
|
1
|
+
# qase-javascript-commons@2.2.6
|
|
2
|
+
|
|
3
|
+
## What's new
|
|
4
|
+
|
|
5
|
+
Added error handling for HTTP status 422 in API responses, returning a descriptive QaseError with relevant details.
|
|
6
|
+
|
|
7
|
+
# qase-javascript-commons@2.2.5
|
|
8
|
+
|
|
9
|
+
## What's new
|
|
10
|
+
|
|
11
|
+
Use the API v2 client by default. If you want to use the API v1 client, specify the `useV2` option in the config file or
|
|
12
|
+
the environment variable `QASE_TESTOPS_USEV2` as `False`.
|
|
13
|
+
|
|
1
14
|
# qase-javascript-commons@2.2.3
|
|
2
15
|
|
|
3
16
|
## What's new
|
|
@@ -47,7 +47,7 @@ class TestOpsReporter extends abstract_reporter_1.AbstractReporter {
|
|
|
47
47
|
this.environment = environment;
|
|
48
48
|
this.planId = plan.id;
|
|
49
49
|
this.batchSize = options.batch?.size ?? defaultChunkSize;
|
|
50
|
-
this.useV2 = options.useV2 ??
|
|
50
|
+
this.useV2 = options.useV2 ?? true;
|
|
51
51
|
this.defect = options.defect ?? false;
|
|
52
52
|
this.rootSuite = rootSuite;
|
|
53
53
|
}
|
|
@@ -542,7 +542,7 @@ class TestOpsReporter extends abstract_reporter_1.AbstractReporter {
|
|
|
542
542
|
if (error.response?.status === 404) {
|
|
543
543
|
return new qase_error_1.QaseError(message + ': Not found.');
|
|
544
544
|
}
|
|
545
|
-
if (error.response?.status === 400) {
|
|
545
|
+
if (error.response?.status === 400 || error.response?.status === 422) {
|
|
546
546
|
return new qase_error_1.QaseError(message + ': Bad request. Body: \n ' + JSON.stringify(model));
|
|
547
547
|
}
|
|
548
548
|
return new qase_error_1.QaseError(message, { cause: error });
|