Drop standalonePageModel snippet from agentless contract test; bump test timeout to 20m

TestAgentlessAvailabilityTargetKindStaysCanonical was pinning the
former agentless-machine classification in
frontend-modern/src/features/standalone/standalonePageModel.ts
(resource.availability?.targetKind,
availabilityTargetKindFor(resource) === 'machine'). Commit 1e16cf34f
intentionally narrowed the Machines surface to Pulse Agent resources
only, removing that classification, but did not update the test. The
server-side contract for availability targetKind across
config/availability.go, monitoring/availability_poller.go, types.go,
and frontend-modern/src/api/availabilityTargets.ts is preserved and
still pinned by the same test for any future consumer.

Makefile go test timeout bumped from 10m to 20m. The rc.5 backend
test run cleared 10m with slack; the rc.6 backend test run hit 13m
in internal/api before the binary panic-killed itself. 20m gives
headroom without hiding regressions for the rc.6 release path while
the package-size growth is tracked separately.
This commit is contained in:
rcourtman 2026-05-27 17:17:13 +01:00
parent 3e4cc1a198
commit 3e61849242
2 changed files with 8 additions and 6 deletions

View file

@ -91,7 +91,7 @@ control-plane:
test:
@./scripts/ensure_test_assets.sh
@echo "Running backend tests..."
go test -race -timeout 10m $$(go list $(GO_TEST_PACKAGES))
go test -race -timeout 20m $$(go list $(GO_TEST_PACKAGES))
# Run integration tests (requires Ollama at OLLAMA_URL or 127.0.0.1:11434)
test-integration:

View file

@ -296,11 +296,13 @@ func TestAgentlessAvailabilityTargetKindStaysCanonical(t *testing.T) {
"export type AvailabilityTargetKind = 'machine' | 'service' | 'device';",
"targetKind?: AvailabilityTargetKind;",
},
filepath.Join("..", "..", "frontend-modern", "src", "features", "standalone", "standalonePageModel.ts"): {
"resource.availability?.targetKind",
"resource.platformData?.availability as { targetKind?: string }",
"availabilityTargetKindFor(resource) === 'machine'",
},
// standalonePageModel.ts no longer references targetKind: commit
// 1e16cf34f intentionally narrowed the Machines surface to Pulse
// Agent resources only, so agentless availability targets are no
// longer classified by kind for the Machines list. The server
// contract (config/availability.go, monitoring/availability_poller.go,
// types.go, frontend-modern/src/api/availabilityTargets.ts) still
// preserves targetKind for any future UI that wants to consume it.
}
for path, snippets := range requiredSnippets {