hub v0.176.1: Restart controller for every guest of a customer host (0.176.0 gated it on a controller version the agent does not report — found live); R-1345 filed (token scopes cannot be edited) — test red first
gates / gates (push) Successful in 1m46s

This commit is contained in:
admin committed 2026-10-29 12:57:14 +01:00
1 parent 682015db86
commit d0dbc6f1cd
5 files changed
+29 -5

No files matched your search

+3 -3
View File
@@ -174,8 +174,8 @@ func TestHandleHostDetail(t *testing.T) {
// Decision 185 (2026-10-08): plus the four operator-action buttons — a closed list, none of which
// deletes or mutates the host (TestOperatorActions_* pin what they may do). Every OTHER button
// remains absent: 2 log requests + 4 operator actions, and the 4 all post to /operator-action.
// 2026-10-29 (operator brief, Part 1): plus ONE „Restart controller" per guest that runs a controller (the AGENT's
// closed list, behind a confirm step; this fixture has one such guest). „Clear hold" appears only per held app (none
// 2026-10-29 (operator brief, Part 1): plus ONE „Restart controller" per guest of a customer host (the AGENT's closed
// list, behind a confirm step; this fixture has one guest). „Clear hold" appears only per held app (none
// here). No other button.
if got := strings.Count(strings.ToLower(body), "<button"); got != 7 {
t.Errorf("host detail has %d buttons, want exactly the 2 log-request + 4 operator-action + 1 restart-controller buttons", got)
@@ -184,7 +184,7 @@ func TestHandleHostDetail(t *testing.T) {
t.Errorf("operator-action forms = %d, want 5", got)
}
if got := strings.Count(body, `value="restart_controller"`); got != 1 {
t.Errorf("restart_controller forms = %d, want 1 (one guest with a controller)", got)
t.Errorf("restart_controller forms = %d, want 1 (one guest)", got)
}
if strings.Count(body, `action="/hosts/demo-felhom-01/request-logs"`) != 2 {
t.Error("the request-logs forms are missing — every button must be a log-bundle request")