forked from baron/baron-sso
fix: stabilize tests and refine RBAC model for privileged roles
- Updated devfront to recognize 'rp_admin' and 'tenant_admin' as privileged developer roles. - Added specific forbidden messages for privileged roles in devfront. - Improved adminfront Worksmobile test reliability across browsers. - Updated Makefile to skip userfront tests in environments without Flutter SDK. - Applied lint and format fixes across adminfront and devfront.
This commit is contained in:
@@ -1,5 +1,5 @@
|
||||
import { act } from "react-dom/test-utils";
|
||||
import { createRoot } from "react-dom/client";
|
||||
import { act } from "react-dom/test-utils";
|
||||
import { afterEach, describe, expect, it, vi } from "vitest";
|
||||
import { DeveloperAccessRequestCard } from "./DeveloperAccessRequestCard";
|
||||
|
||||
|
||||
@@ -34,6 +34,16 @@ export function ForbiddenMessage({ resourceToken }: Props) {
|
||||
"Standard user accounts can use this feature only when an operational or administrative relationship is granted for the target application. Request access from an administrator if needed.",
|
||||
);
|
||||
}
|
||||
} else if (role === "rp_admin") {
|
||||
explanation = t(
|
||||
"msg.dev.forbidden.rp_admin",
|
||||
"RP administrators can only access resources for their assigned applications.",
|
||||
);
|
||||
} else if (role === "tenant_admin") {
|
||||
explanation = t(
|
||||
"msg.dev.forbidden.tenant_admin",
|
||||
"Tenant administrator permissions are not configured correctly or have expired.",
|
||||
);
|
||||
}
|
||||
|
||||
const resourceLabel =
|
||||
|
||||
Reference in New Issue
Block a user