Refresh HiveGrid Cloud reference snapshot
This commit is contained in:
1 parent
5e99e14772
commit
7f88026f79
5955 files changed
+1177325
-188362
No files matched your search
+18
-14
@@ -1,18 +1,24 @@
|
||||
import { expect, test } from "./utils/test";
|
||||
import { expectNoCriticalA11yViolations } from "./utils/axe";
|
||||
import { getTenantCredentials, loginAsTenantUser, tenantRolesAndPermissionsPath, tenantSettingsMembersPath } from "./utils/auth";
|
||||
import {
|
||||
getTenantCredentials,
|
||||
loginAsTenantUser,
|
||||
tenantLegacyRolesAndPermissionsPath,
|
||||
tenantRolesAndPermissionsPath,
|
||||
tenantSettingsMembersPath,
|
||||
} from "./utils/auth";
|
||||
import { compactMobileViewport, expectNoHorizontalOverflow, narrowMobileViewport } from "./utils/mobile";
|
||||
import { escapeRegExp, interceptCurrentRoutePost, postDataIncludesField, skipIfUnavailable } from "./utils/navigation";
|
||||
import { skipOrFailWhenE2eFixtureMissing, skipOrFailWhenE2eInputsMissing } from "./utils/readiness";
|
||||
|
||||
// R-P2b (D-P2 Admin RBAC): one merged "Rollen und Berechtigungen" tab (S02);
|
||||
// role assignment happens inline in the members list (D01 dropdown) instead of
|
||||
// the old users matrix (route redirects to settings/members).
|
||||
// the old users matrix (route redirects to settings/team).
|
||||
|
||||
const credentials = getTenantCredentials();
|
||||
const dashboardPath = process.env.E2E_TENANT_DASHBOARD_PATH;
|
||||
const rolesAndPermissionsPath =
|
||||
process.env.E2E_TENANT_ROLES_AND_PERMISSIONS_PATH ?? (dashboardPath ? tenantRolesAndPermissionsPath(dashboardPath) : undefined);
|
||||
const rolesAndPermissionsPath = process.env.E2E_TENANT_ROLES_AND_PERMISSIONS_PATH ?? (dashboardPath ? tenantRolesAndPermissionsPath(dashboardPath) : undefined);
|
||||
const legacyRolesAndPermissionsPath = dashboardPath ? tenantLegacyRolesAndPermissionsPath(dashboardPath) : undefined;
|
||||
const membersPath = process.env.E2E_TENANT_MEMBERS_PATH ?? (dashboardPath ? tenantSettingsMembersPath(dashboardPath) : undefined);
|
||||
|
||||
test.describe("tenant roles and permissions mobile a11y", () => {
|
||||
@@ -23,7 +29,7 @@ test.describe("tenant roles and permissions mobile a11y", () => {
|
||||
["E2E_TENANT_EMAIL", "E2E_TENANT_PASSWORD", "E2E_TENANT_DASHBOARD_PATH"],
|
||||
"Tenant roles and permissions mobile E2E inputs not configured"
|
||||
);
|
||||
if (!rolesAndPermissionsPath) {
|
||||
if (!rolesAndPermissionsPath || !legacyRolesAndPermissionsPath) {
|
||||
skipOrFailWhenE2eFixtureMissing("Tenant roles and permissions path could not be derived; set E2E_TENANT_ROLES_AND_PERMISSIONS_PATH");
|
||||
}
|
||||
});
|
||||
@@ -36,11 +42,9 @@ test.describe("tenant roles and permissions mobile a11y", () => {
|
||||
const response = await page.goto(rolesAndPermissionsPath!, { waitUntil: "domcontentloaded" });
|
||||
await skipIfUnavailable(page, response, `Tenant roles and permissions path ${rolesAndPermissionsPath}`);
|
||||
|
||||
const rolesPath = `${rolesAndPermissionsPath}/roles`;
|
||||
|
||||
// Index redirects into the merged S02 roles tab.
|
||||
await expect(page).toHaveURL(new RegExp(`${escapeRegExp(rolesPath)}(?:[?#].*)?$`, "u"));
|
||||
await expect(page.locator('[data-ui-id="ui.settings.rolesAndPermissions.page"]').first()).toBeVisible();
|
||||
// The helper resolves directly to the canonical Team-Hub roles tab.
|
||||
await expect(page).toHaveURL(new RegExp(`${escapeRegExp(rolesAndPermissionsPath!)}(?:[?#].*)?$`, "u"));
|
||||
await expect(page.locator('[data-ui-id="ui.settings.hub.team"]').first()).toBeVisible();
|
||||
await expect(page.locator('[data-ui-id="ui.settings.rolesAndPermissions.roles"] table').first()).toBeVisible();
|
||||
await expect(page.locator('[data-ui-id="ui.settings.rolesAndPermissions.roles.filter"]').first()).toBeVisible();
|
||||
|
||||
@@ -54,8 +58,8 @@ test.describe("tenant roles and permissions mobile a11y", () => {
|
||||
await expectNoCriticalA11yViolations(page);
|
||||
|
||||
// Legacy permissions sub-tab redirects into the merged roles tab.
|
||||
await page.goto(`${rolesAndPermissionsPath}/permissions`, { waitUntil: "domcontentloaded" });
|
||||
await expect(page).toHaveURL(new RegExp(`${escapeRegExp(rolesPath)}(?:[?#].*)?$`, "u"));
|
||||
await page.goto(`${legacyRolesAndPermissionsPath}/permissions`, { waitUntil: "domcontentloaded" });
|
||||
await expect(page).toHaveURL(new RegExp(`${escapeRegExp(rolesAndPermissionsPath!)}(?:[?#].*)?$`, "u"));
|
||||
await expectNoHorizontalOverflow(page);
|
||||
await expectNoCriticalA11yViolations(page);
|
||||
});
|
||||
@@ -69,8 +73,8 @@ test.describe("tenant roles and permissions mobile a11y", () => {
|
||||
skipOrFailWhenE2eFixtureMissing("Tenant members path could not be derived; set E2E_TENANT_MEMBERS_PATH");
|
||||
}
|
||||
// The old users matrix redirects to the members list; D01 lives there now.
|
||||
const response = await page.goto(`${rolesAndPermissionsPath}/users`, { waitUntil: "domcontentloaded" });
|
||||
await skipIfUnavailable(page, response, `Tenant roles users path ${rolesAndPermissionsPath}/users`);
|
||||
const response = await page.goto(`${legacyRolesAndPermissionsPath}/users`, { waitUntil: "domcontentloaded" });
|
||||
await skipIfUnavailable(page, response, `Tenant roles users path ${legacyRolesAndPermissionsPath}/users`);
|
||||
await expect(page).toHaveURL(new RegExp(`${escapeRegExp(membersPath!)}(?:[?#].*)?$`, "u"));
|
||||
|
||||
const roleDropdown = page.locator('[data-ui-id="ui.settings.members.roleDropdown"]').first();
|
||||
|
||||
Reference in new issue
Block a user