feat(админка): client-error без PII

This commit is contained in:
anor
2026-11-06 23:17:08 +10:00
parent 3596ff544c
commit bff50e3eb2
10 changed files with 203 additions and 1 deletions
+4 -1
View File
@@ -18,6 +18,8 @@ SYS = {"channels": [{"name": "database", "ok": True, "detail": "ок", "level":
"settings": [{"key": "agent_killswitch", "value": "off"}],
"history": [{"id": 1, "timestamp": 1793000000, "label": "переключение слоя",
"username": "boss@x", "detail": "x → on"}],
"errors": {"items": [{"id": 1, "ts": 1793000000, "username": "a@x",
"message": "boom", "path": "/admin/v2"}], "total": 1},
"generated_at": 1793000000}
@@ -67,10 +69,11 @@ def test_system_page(browser, site):
page.add_init_script("localStorage.setItem('token','t')")
page.goto(site + "/admin/v2/system")
page.wait_for_selector(".grid .card")
assert page.locator(".grid .card").count() == 3
assert page.locator(".grid .card").count() == 4
assert "smtp" in page.locator("main").inner_text()
assert "agent_killswitch" in page.locator("main").inner_text()
assert "переключение слоя" in page.locator("main").inner_text()
assert "127.0.0.1" in page.locator("main").inner_text()
assert "boom" in page.locator("main").inner_text()
assert errors == []
page.close()