Skip to content

Commit 525f41c

Browse files
committed
5317: remove acess config from tests
1 parent dd62356 commit 525f41c

File tree

3 files changed

+2
-45
lines changed

3 files changed

+2
-45
lines changed

assets/tests/admin/admin-login.spec.js

Lines changed: 1 addition & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -1,24 +1,14 @@
11
import { test, expect } from "@playwright/test";
22
import {
3-
accessConfigJson,
43
adminConfigJson,
5-
emptyJson,
64
tokenAdminJson,
75
tokenEditorJson,
86
tokenTenantsJson,
97
} from "./data-fixtures.js";
10-
import {
11-
fulfillDataRoute,
12-
fulfillEmptyRoutes,
13-
beforeEachTest,
14-
} from "./test-helper.js";
8+
import { fulfillDataRoute, fulfillEmptyRoutes } from "./test-helper.js";
159

1610
test.describe("Login works", () => {
1711
test.beforeEach(async ({ page }) => {
18-
await page.route("**/access-config.json", async (route) => {
19-
await route.fulfill({ json: accessConfigJson });
20-
});
21-
2212
await page.route("**/config/admin", async (route) => {
2313
await route.fulfill({ json: adminConfigJson });
2414
});

assets/tests/admin/data-fixtures.js

Lines changed: 0 additions & 22 deletions
Original file line numberDiff line numberDiff line change
@@ -410,27 +410,6 @@ const clientConfigJson = {
410410
logging: false,
411411
};
412412

413-
const accessConfigJson = {
414-
campaign: {
415-
roles: ["ROLE_ADMIN"],
416-
},
417-
screen: {
418-
roles: ["ROLE_ADMIN"],
419-
},
420-
settings: {
421-
roles: ["ROLE_ADMIN"],
422-
},
423-
groups: {
424-
roles: ["ROLE_ADMIN"],
425-
},
426-
shared: {
427-
roles: ["ROLE_ADMIN"],
428-
},
429-
users: {
430-
roles: ["ROLE_ADMIN", "ROLE_EXTERNAL_USER_ADMIN"],
431-
},
432-
};
433-
434413
const slidesJson1 = {
435414
"@id": "/v2/slides",
436415
"hydra:member": [
@@ -1653,7 +1632,6 @@ export {
16531632
errorJson,
16541633
emptyJson,
16551634
slidesJson1,
1656-
accessConfigJson,
16571635
clientConfigJson,
16581636
adminConfigJson,
16591637
mediaListJson,

assets/tests/admin/test-helper.js

Lines changed: 1 addition & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -1,10 +1,4 @@
1-
import {
2-
accessConfigJson,
3-
adminConfigJson,
4-
emptyJson,
5-
feedSourcesJson,
6-
tokenAdminJson,
7-
} from "./data-fixtures.js";
1+
import { adminConfigJson, emptyJson, tokenAdminJson } from "./data-fixtures.js";
82
import { expect } from "@playwright/test";
93

104
const beforeEachTest = async (page) => {
@@ -13,11 +7,6 @@ const beforeEachTest = async (page) => {
137
await route.abort();
148
});
159

16-
// Handle calls to cccess-config.
17-
await page.route("**/access-config.json*", async (route) => {
18-
await route.fulfill({ json: accessConfigJson });
19-
});
20-
2110
// Handle all calls to config.
2211
await page.route("**/config/admin", async (route) => {
2312
await route.fulfill({ json: adminConfigJson });

0 commit comments

Comments
 (0)