forked from baron/baron-sso
fix: resolve unit and integration test failures in adminfront
- Updated roles test to align with simplified RBAC model. - Fixed AppLayout test navigation label order. - Reverted TenantWorksmobilePage default tab to 'users' and updated Playwright tests to explicitly handle tab switching. - Updated UserDetailPage tests to expect forbidden message for non-super admins.
This commit is contained in:
@@ -100,9 +100,10 @@ describe("admin AppLayout", () => {
|
||||
expect(screen.getByText("Admin Control")).toBeInTheDocument();
|
||||
expect(screen.getByText("Users outlet")).toBeInTheDocument();
|
||||
expect(screen.getByText("Tenants")).toBeInTheDocument();
|
||||
expect(screen.getByText("Org Chart")).toBeInTheDocument();
|
||||
expect(screen.getByText("Worksmobile")).toBeInTheDocument();
|
||||
expect(screen.getByText("User Projection")).toBeInTheDocument();
|
||||
expect(screen.getByText("Data Integrity")).toBeInTheDocument();
|
||||
expect(screen.queryByText("User Projection")).not.toBeInTheDocument();
|
||||
const navigation = screen.getByRole("navigation");
|
||||
const navLabels = Array.from(navigation.querySelectorAll("a")).map((link) =>
|
||||
link.textContent?.trim(),
|
||||
@@ -110,9 +111,11 @@ describe("admin AppLayout", () => {
|
||||
expect(navLabels).toEqual([
|
||||
"Overview",
|
||||
"Tenants",
|
||||
"Org Chart",
|
||||
"Worksmobile",
|
||||
"Users",
|
||||
"User Projection",
|
||||
"Data Integrity",
|
||||
"Users",
|
||||
"Auth Guard",
|
||||
"API Keys",
|
||||
"Audit Logs",
|
||||
|
||||
Reference in New Issue
Block a user