@gooddata/sdk-backend-mockingbird 11.54.0-alpha.6 → 11.54.0-alpha.7
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.
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/recordedBackend/index.ts"],"names":[],"mappings":"AAQA,OAAO,EACH,KAAK,kBAAkB,EAKvB,KAAK,oBAAoB,
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/recordedBackend/index.ts"],"names":[],"mappings":"AAQA,OAAO,EACH,KAAK,kBAAkB,EAKvB,KAAK,oBAAoB,EAwD5B,MAAM,2BAA2B,CAAC;AAkCnC,OAAO,EAAE,KAAK,qBAAqB,EAAE,KAAK,cAAc,EAAE,MAAM,YAAY,CAAC;AAkB7E;;GAEG;AACH,eAAO,MAAM,kCAAkC,EAAE,oBAehD,CAAC;AAEF;;;;;;;;;;;;;;GAcG;AACH,wBAAgB,eAAe,CAC3B,KAAK,EAAE,cAAc,EACrB,MAAM,GAAE,qBAAqC,EAC7C,YAAY,uBAAqC,GAClD,kBAAkB,CAsDpB"}
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
// (C) 2019-2026 GoodData Corporation
|
|
2
2
|
import { DummyChatConversations, DummyGenAIChatThread, DummySemanticSearchQueryBuilder, InMemoryPaging, } from "@gooddata/sdk-backend-base";
|
|
3
|
-
import { NotSupported, } from "@gooddata/sdk-backend-spi";
|
|
4
|
-
import { idRef, isIdentifierRef, } from "@gooddata/sdk-model";
|
|
3
|
+
import { NotSupported, UnexpectedResponseError, } from "@gooddata/sdk-backend-spi";
|
|
4
|
+
import { BuiltInReportPageLayouts, areObjRefsEqual, idRef, isIdentifierRef, } from "@gooddata/sdk-model";
|
|
5
5
|
import { createMockGeoService } from "../geoService.js";
|
|
6
6
|
import { RecordedAttributeHierarchiesService } from "./attributeHierarchies.js";
|
|
7
7
|
import { RecordedAttributes } from "./attributes.js";
|
|
@@ -447,6 +447,45 @@ function recordedWorkspace(workspace, recordings = {}, implConfig) {
|
|
|
447
447
|
deleteExportTemplate: () => Promise.resolve(),
|
|
448
448
|
};
|
|
449
449
|
},
|
|
450
|
+
reports() {
|
|
451
|
+
return {
|
|
452
|
+
getReportPageLayouts: () => Promise.resolve([...BuiltInReportPageLayouts]),
|
|
453
|
+
getReportPageLayout: (ref) => {
|
|
454
|
+
const page = BuiltInReportPageLayouts.find((candidate) => areObjRefsEqual(candidate.ref, ref));
|
|
455
|
+
if (!page) {
|
|
456
|
+
throw new UnexpectedResponseError("Report page not found", 404, {});
|
|
457
|
+
}
|
|
458
|
+
return Promise.resolve(page);
|
|
459
|
+
},
|
|
460
|
+
createReportPageLayout: (page) => Promise.resolve({ ...page, ref: idRef("recordedReportPage") }),
|
|
461
|
+
updateReportPageLayout: (page) => {
|
|
462
|
+
if (BuiltInReportPageLayouts.some((candidate) => areObjRefsEqual(candidate.ref, page.ref))) {
|
|
463
|
+
throw new NotSupported("Built-in report page layouts cannot be updated.");
|
|
464
|
+
}
|
|
465
|
+
return Promise.resolve(page);
|
|
466
|
+
},
|
|
467
|
+
deleteReportPageLayout: (ref) => {
|
|
468
|
+
if (BuiltInReportPageLayouts.some((candidate) => areObjRefsEqual(candidate.ref, ref))) {
|
|
469
|
+
throw new NotSupported("Built-in report page layouts cannot be deleted.");
|
|
470
|
+
}
|
|
471
|
+
return Promise.resolve();
|
|
472
|
+
},
|
|
473
|
+
getReportTemplates: () => Promise.resolve([]),
|
|
474
|
+
getReportTemplate: () => {
|
|
475
|
+
throw new UnexpectedResponseError("Report template not found", 404, {});
|
|
476
|
+
},
|
|
477
|
+
createReportTemplate: (template) => Promise.resolve({ ...template, ref: idRef("recordedReportTemplate") }),
|
|
478
|
+
updateReportTemplate: (template) => Promise.resolve(template),
|
|
479
|
+
deleteReportTemplate: () => Promise.resolve(),
|
|
480
|
+
getReports: () => Promise.resolve([]),
|
|
481
|
+
getReport: () => {
|
|
482
|
+
throw new UnexpectedResponseError("Report not found", 404, {});
|
|
483
|
+
},
|
|
484
|
+
createReport: (report) => Promise.resolve({ ...report, ref: idRef("recordedReport") }),
|
|
485
|
+
updateReport: (report) => Promise.resolve(report),
|
|
486
|
+
deleteReport: () => Promise.resolve(),
|
|
487
|
+
};
|
|
488
|
+
},
|
|
450
489
|
};
|
|
451
490
|
}
|
|
452
491
|
function recordedEntitlements() {
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@gooddata/sdk-backend-mockingbird",
|
|
3
|
-
"version": "11.54.0-alpha.
|
|
3
|
+
"version": "11.54.0-alpha.7",
|
|
4
4
|
"description": "Mock GoodData Backend SPI implementation",
|
|
5
5
|
"license": "MIT",
|
|
6
6
|
"author": "GoodData",
|
|
@@ -25,13 +25,13 @@
|
|
|
25
25
|
"ts-invariant": "0.10.3",
|
|
26
26
|
"tslib": "2.8.1",
|
|
27
27
|
"uuid": "11.1.1",
|
|
28
|
-
"@gooddata/sdk-backend-base": "11.54.0-alpha.
|
|
29
|
-
"@gooddata/sdk-
|
|
30
|
-
"@gooddata/
|
|
31
|
-
"@gooddata/
|
|
28
|
+
"@gooddata/sdk-backend-base": "11.54.0-alpha.7",
|
|
29
|
+
"@gooddata/sdk-backend-spi": "11.54.0-alpha.7",
|
|
30
|
+
"@gooddata/sdk-model": "11.54.0-alpha.7",
|
|
31
|
+
"@gooddata/util": "11.54.0-alpha.7"
|
|
32
32
|
},
|
|
33
33
|
"devDependencies": {
|
|
34
|
-
"@microsoft/api-documenter": "
|
|
34
|
+
"@microsoft/api-documenter": "7.30.10",
|
|
35
35
|
"@microsoft/api-extractor": "^7.55.2",
|
|
36
36
|
"@types/lodash-es": "^4.17.12",
|
|
37
37
|
"@typescript-eslint/eslint-plugin": "8.58.0",
|
|
@@ -52,9 +52,9 @@
|
|
|
52
52
|
"oxlint-tsgolint": "0.15.0",
|
|
53
53
|
"typescript": "5.9.3",
|
|
54
54
|
"vitest": "4.1.8",
|
|
55
|
-
"@gooddata/eslint-config": "11.54.0-alpha.
|
|
56
|
-
"@gooddata/oxlint-config": "11.54.0-alpha.
|
|
57
|
-
"@gooddata/reference-workspace": "11.54.0-alpha.
|
|
55
|
+
"@gooddata/eslint-config": "11.54.0-alpha.7",
|
|
56
|
+
"@gooddata/oxlint-config": "11.54.0-alpha.7",
|
|
57
|
+
"@gooddata/reference-workspace": "11.54.0-alpha.7"
|
|
58
58
|
},
|
|
59
59
|
"scripts": {
|
|
60
60
|
"_phase:build": "npm run build",
|