1
0
forked from baron/baron-sso

ci: add code check badges and coverage reports

This commit is contained in:
2026-05-29 12:05:43 +09:00
parent c489c7c38f
commit a830242947
164 changed files with 9059 additions and 2012 deletions

View File

@@ -31,6 +31,8 @@ describe("AuthPage", () => {
expect(screen.getByText("Auth Guard")).toBeInTheDocument();
expect(screen.getByText("ReBAC permission checker")).toBeInTheDocument();
expect(screen.getByRole("button", { name: "Check permission" })).toBeInTheDocument();
expect(
screen.getByRole("button", { name: "Check permission" }),
).toBeInTheDocument();
});
});

View File

@@ -42,7 +42,9 @@ describe("LoginPage", () => {
it("shows an actionable error instead of starting PKCE when WebCrypto is unavailable", async () => {
renderLoginPage("/login?returnTo=%2F");
await userEvent.click(screen.getByRole("button", { name: /SSO 계정으로 로그인/i }));
await userEvent.click(
screen.getByRole("button", { name: /SSO 계정으로 로그인/i }),
);
expect(mockSigninRedirect).not.toHaveBeenCalled();
expect(screen.getByRole("alert")).toHaveTextContent(
@@ -61,7 +63,9 @@ describe("LoginPage", () => {
});
renderLoginPage("/login?returnTo=%2Fusers%3Fpage%3D2");
await userEvent.click(screen.getByRole("button", { name: /SSO 계정으로 로그인/i }));
await userEvent.click(
screen.getByRole("button", { name: /SSO 계정으로 로그인/i }),
);
expect(mockSigninRedirect).toHaveBeenCalledWith({
state: {

View File

@@ -48,10 +48,7 @@ function PermissionChecker() {
<Card className="border-primary/20 bg-[var(--color-panel)]">
<CardHeader>
<CardTitle className="text-lg font-bold">
{t(
"ui.admin.auth_guard.checker.title",
"ReBAC permission checker",
)}
{t("ui.admin.auth_guard.checker.title", "ReBAC permission checker")}
</CardTitle>
<CardDescription>
{t(
@@ -92,7 +89,9 @@ function PermissionChecker() {
</select>
</div>
<div className="space-y-2">
<Label>{t("ui.admin.auth_guard.checker.relation", "Relation")}</Label>
<Label>
{t("ui.admin.auth_guard.checker.relation", "Relation")}
</Label>
<Input
placeholder={t(
"ui.admin.auth_guard.checker.relation_placeholder",
@@ -103,7 +102,9 @@ function PermissionChecker() {
/>
</div>
<div className="space-y-2">
<Label>{t("ui.admin.auth_guard.checker.object_id", "Object ID")}</Label>
<Label>
{t("ui.admin.auth_guard.checker.object_id", "Object ID")}
</Label>
<Input
placeholder={t(
"ui.admin.auth_guard.checker.object_id_placeholder",
@@ -115,10 +116,7 @@ function PermissionChecker() {
</div>
<div className="space-y-2">
<Label>
{t(
"ui.admin.auth_guard.checker.subject",
"Subject (User:ID)",
)}
{t("ui.admin.auth_guard.checker.subject", "Subject (User:ID)")}
</Label>
<Input
placeholder={t(
@@ -155,10 +153,7 @@ function PermissionChecker() {
<>
<CheckCircle2 size={48} />
<div className="text-lg font-bold">
{t(
"ui.admin.auth_guard.checker.allowed",
"Access ALLOWED",
)}
{t("ui.admin.auth_guard.checker.allowed", "Access ALLOWED")}
</div>
<p className="text-center text-sm opacity-80">
{t(
@@ -171,10 +166,7 @@ function PermissionChecker() {
<>
<XCircle size={48} />
<div className="text-lg font-bold">
{t(
"ui.admin.auth_guard.checker.denied",
"Access DENIED",
)}
{t("ui.admin.auth_guard.checker.denied", "Access DENIED")}
</div>
<p className="text-center text-sm opacity-80">
{t(