1
0
forked from baron/baron-sso

test: update adminfront e2e tests for new organization UI

This commit is contained in:
2026-04-17 17:39:28 +09:00
parent 9f3506c530
commit ad5a49b62f
2 changed files with 19 additions and 25 deletions

View File

@@ -87,8 +87,12 @@ test.describe("Bulk Actions and Tree Search", () => {
if (url.includes("/admin/tenants")) {
return route.fulfill({
json: {
items: [{ id: "t-1", name: "Main Tenant", slug: "main" }],
total: 1,
items: [
{ id: "t-1", name: "Main Tenant", slug: "main", type: "COMPANY" },
{ id: "g-1", name: "Engineering", slug: "eng", parentId: "t-1", type: "USER_GROUP" },
{ id: "g-2", name: "Sales", slug: "sales", parentId: "t-1", type: "USER_GROUP" },
],
total: 3,
},
headers,
});
@@ -157,11 +161,11 @@ test.describe("Bulk Actions and Tree Search", () => {
await searchInput.fill("Eng");
const engRow = page
.locator("tr")
const engNode = page
.locator("button")
.filter({ hasText: "Engineering" })
.first();
await expect(engRow).toBeVisible();
await expect(engRow).toHaveClass(/bg-primary/);
await expect(engNode).toBeVisible();
await expect(engNode).toHaveClass(/bg-primary\/5/);
});
});