MCPcopy Create free account
hub / github.com/codehamr/codehamr / TestCheckHonoursEnvDisableFlag

Function TestCheckHonoursEnvDisableFlag

internal/update/update_test.go:296–301  ·  view source on GitHub ↗

TestCheckHonoursEnvDisableFlag: CODEHAMR_NO_UPDATE_CHECK=1 must short-circuit Check before any HTTP work, sparing CI/offline launches the fetch deadline.

(t *testing.T)

Source from the content-addressed store, hash-verified

294// TestCheckHonoursEnvDisableFlag: CODEHAMR_NO_UPDATE_CHECK=1 must short-circuit
295// Check before any HTTP work, sparing CI/offline launches the fetch deadline.
296func TestCheckHonoursEnvDisableFlag(t *testing.T) {
297 t.Setenv("CODEHAMR_NO_UPDATE_CHECK", "1")
298 if Check(context.Background(), "/nonexistent/binary") {
299 t.Fatal("Check must return false when the env disable flag is set")
300 }
301}
302
303// TestAssetNameCoversEveryReleasedPlatform: every goos/goarch goreleaser
304// publishes a binary for MUST be reachable from assetName. A missing case

Callers

nothing calls this directly

Calls 1

CheckFunction · 0.85

Tested by

no test coverage detected