feat(web): расписание, каналы уведомлений, история проверок, drift-badge

This commit is contained in:
2026-07-04 14:40:29 +07:00
parent 45259b9720
commit 34422420ca
14 changed files with 937 additions and 3 deletions
+11 -2
View File
@@ -18,8 +18,8 @@ const templates: Template[] = [
{ id: "t2", name: "Minimal", records: [], version: 1 },
]
const domains: Domain[] = [
{ id: "d1", providerAccountId: "acc1", zoneName: "example.com.", zoneId: "z1", templateId: null },
{ id: "d2", providerAccountId: "acc2", zoneName: "test.org.", zoneId: "z2", templateId: "t1" },
{ id: "d1", providerAccountId: "acc1", zoneName: "example.com.", zoneId: "z1", templateId: null, lastCheckStatus: "drift" },
{ id: "d2", providerAccountId: "acc2", zoneName: "test.org.", zoneId: "z2", templateId: "t1", lastCheckStatus: "in_sync" },
]
function renderPage() {
@@ -108,3 +108,12 @@ test("пустое состояние при отсутствии доменов
expect(await screen.findByText(/доменов пока нет/i)).toBeInTheDocument()
})
test("drift-badge отражает lastCheckStatus каждого домена", async () => {
renderPage()
await screen.findByText("example.com.")
expect(screen.getByText("drift")).toBeInTheDocument()
expect(screen.getByText("in sync")).toBeInTheDocument()
})