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:
@@ -194,7 +194,7 @@ export function TenantWorksmobilePage() {
|
||||
const tenantId = params.tenantId ?? HANMAC_FAMILY_TENANT_ID;
|
||||
const [orgUnitId, setOrgUnitId] = React.useState("");
|
||||
const [userId, setUserId] = React.useState("");
|
||||
const [activeTab, setActiveTab] = React.useState("history");
|
||||
const [activeTab, setActiveTab] = React.useState("users");
|
||||
const [userFilters, setUserFilters] = React.useState<
|
||||
WorksmobileComparisonFilter[]
|
||||
>(getDefaultUserComparisonFilters);
|
||||
|
||||
@@ -131,13 +131,13 @@ describe("UserDetailPage Worksmobile employee number", () => {
|
||||
);
|
||||
});
|
||||
|
||||
it("keeps email read-only for non-super admin", async () => {
|
||||
it("shows forbidden message for non-super admin", async () => {
|
||||
profileRoleMock.role = "tenant_admin";
|
||||
renderUserDetailPage();
|
||||
|
||||
const emailInput = await screen.findByLabelText("이메일");
|
||||
|
||||
expect(emailInput).toBeDisabled();
|
||||
expect(
|
||||
await screen.findByText("이 작업을 수행할 권한이 없습니다."),
|
||||
).toBeInTheDocument();
|
||||
});
|
||||
|
||||
it("removes metadata employee_id when the field is cleared", async () => {
|
||||
|
||||
Reference in New Issue
Block a user