@api-client/core 0.18.36 → 0.18.37
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/package.json
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@api-client/core",
|
|
3
3
|
"description": "The API Client's core client library. Works in NodeJS and in a ES enabled browser.",
|
|
4
|
-
"version": "0.18.
|
|
4
|
+
"version": "0.18.37",
|
|
5
5
|
"license": "Apache-2.0",
|
|
6
6
|
"exports": {
|
|
7
7
|
"./browser.js": {
|
|
@@ -92,7 +92,7 @@
|
|
|
92
92
|
"@pawel-up/csv": "^0.2.0",
|
|
93
93
|
"@pawel-up/data-mock": "^0.4.0",
|
|
94
94
|
"@pawel-up/jexl": "^4.0.1",
|
|
95
|
-
"@types/sinon": "^
|
|
95
|
+
"@types/sinon": "^21.0.0",
|
|
96
96
|
"@xmldom/xmldom": "^0.8.11",
|
|
97
97
|
"amf-json-ld-lib": "^0.0.15",
|
|
98
98
|
"chalk": "^5.4.1",
|
|
@@ -116,6 +116,7 @@
|
|
|
116
116
|
"@japa/runner": "^4.2.0",
|
|
117
117
|
"@pawel-up/semver": "^0.1.4",
|
|
118
118
|
"@rollup/plugin-typescript": "^12.1.2",
|
|
119
|
+
"@types/chai-as-promised": "^8.0.2",
|
|
119
120
|
"@types/cors": "^2.8.12",
|
|
120
121
|
"@types/express-ntlm": "^2.3.3",
|
|
121
122
|
"@types/jsdom": "^27.0.0",
|
|
@@ -128,6 +129,7 @@
|
|
|
128
129
|
"@web/test-runner-playwright": "^0.11.0",
|
|
129
130
|
"amf-client-js": "^5.9.1-3",
|
|
130
131
|
"c8": "^10.1.3",
|
|
132
|
+
"chai-as-promised": "^8.0.2",
|
|
131
133
|
"conventional-changelog-cli": "^5.0.0",
|
|
132
134
|
"cors": "^2.8.5",
|
|
133
135
|
"eslint": "^9.20.1",
|
package/src/sdk/SdkMock.ts
CHANGED
|
@@ -368,7 +368,7 @@ export class SdkMock {
|
|
|
368
368
|
return this.createStub('user', 'me', () => {
|
|
369
369
|
const defaultData = this.generateUser()
|
|
370
370
|
if (options?.status !== undefined && options.status !== 200) {
|
|
371
|
-
throw new Exception(
|
|
371
|
+
throw new Exception(`Mocked error. Status: ${options.status}`, { status: options.status })
|
|
372
372
|
}
|
|
373
373
|
return (options?.data ?? defaultData) as unknown
|
|
374
374
|
})
|