Observe

Testing Health

Not how many tests exist, but whether a regression would be caught. A suite can grow forever while the share of behaviour it actually pins falls, and no count of tests can show that. Every metric here belongs to one of three questions; anything belonging to none is volume, and is deliberately absent.

Needs attention

MetricQuestionValueWhat to do
Enrolled RFCs with zero test-proven requirementsQ236 / 166Pick the largest and complete a pair, or accept it is a single-polarity claim.
Logged known-failing testsQ31Fix or delete the oldest entry; a permanently logged failure is a deleted test with extra steps.

Sensitivity

If the code were wrong, would something go red?

Tests with no reachable failure call

136 / 20389 (floor 136) Within threshold

136 of 20389 (0.7%)

These execute code and pass unconditionally. Breaking the code under test would not turn them red.

If this degrades: Add a real assertion, or annotate with `// test-asserts-nothing: <why>` when the oracle is genuinely implicit (a must-not-panic smoke test).

filetest
cmd/ze/hub/aaa_lifecycle_test.goTestCloseAAABundleNoBundle
internal/chaos/chaos_test.goTestChaosConcurrency
internal/chaos/watchdog/watchdog_test.goTestWatchdogRouteRegression
internal/component/bfd/api/registry_test.goTestSetGetService_ConcurrentNoRace
internal/component/bfd/metrics_test.goTestMetricsHookStateChangeCounters
internal/component/bfd/metrics_test.goTestRefreshSessionsGauge
internal/component/bgp/plugins/bmp/event_test.goTestBMPPeerUpSkippedOnCacheMiss
internal/component/bgp/plugins/bmp/event_test.goTestHandleSenderNoSenders
internal/component/bgp/plugins/bmp/route_action_test.goTestProcessRouteMonitoring_MonitorMode_StoresInBMPRIB
internal/component/bgp/plugins/bmp/route_action_test.goTestProcessRouteMonitoring_ShortUpdate_Skipped

Mutants killed, latest sample per package

4294 / 7112 Within threshold

4294 of 7112 (60.4%)

60.4% across 22 of the repository's packages. Mutation operators are biased toward arithmetic, conditionals and returns, and are nearly blind to concurrency and wire-format semantics.

If this degrades: Take the lowest-scoring package and add tests until its survivors die.

packagescore
internal/plugins/static/events0.0
internal/plugins/static/vpp0.0
internal/core/crashlog28.1
internal/plugins/static34.7
internal/core/privilege34.7
internal/plugins/sysrib51.4
internal/component/bgp/format53.2
internal/component/bgp/attrpool62.3
internal/core/events66.5
internal/core/slogutil66.8

time.sleep() calls in .ci tests

114 (floor 114) Within threshold

A sleep is a guess about timing that hides the race it was added to mask. The ratchet allows the count to fall, never rise.

If this degrades: Replace a sleep with a payload-predicate wait (wait_until, dispatch_until), then lower the floor in the same change.

Intent coverage

Are the things that matter checked, or only the happy path?

Enrolled RFCs with zero test-proven requirements

36 / 166 Needs attention

36 of 166 (21.7%)

Enrolled and gate-green, but no requirement is proven by BOTH polarities. Some of these do carry positive-only tests; none carries a pair.

If this degrades: Pick the largest and complete a pair, or accept it is a single-polarity claim.

RFC MUST requirements proven by a positive+negative test pair

974 / 2720 Within threshold

974 of 2720 (35.8%)

35.8% carry both polarities. Of the remaining 1746: 841 not-applicable (ze deliberately does not do it, so no test is owed), 535 known gap (unimplemented, genuinely untested), and 370 single-polarity -- those DO have a passing tagged test, just one side of the pair, and the RFC gate fails if that test is missing. Only the gap column is untested work.

If this degrades: Convert a {gap} or {single-polarity} annotation into a test pair. Not-applicable needs no test.

gatedrfc
38rfc7871
34rfc2132
23rfc4213
18rfc4761
17rfc3032
17rfc7166
16rfc4862
13rfc2003
13rfc6396
13rfc9514

In-repo test inventory

20419 test functions Within threshold

2698 Go test files, 72 fuzz targets, 122 benchmarks, 1464 .ci scenarios, 164 .et editor tests. Counts cover internal, cmd, pkg, scripts, test only: vendor/ and gokrazy/modcache/ are third-party module trees and are excluded.

If this degrades: This is volume, not health. It is here to state the counting boundary, because a count that silently includes vendored tests inflates by ~6x.

Test files that expect a specific error

879 / 2698 Within threshold

879 of 2698 (32.6%)

Counts files using an error-expectation token (wantErr, ErrorIs, assert.Error, ...), with comments stripped. Setup guards of the form `if err != nil { t.Fatal(err) }` are deliberately NOT counted: those assert the happy path. Blind spot: expecting *an* error is weaker than pinning the right one.

If this degrades: Take the lowest-ranked subsystem and add malformed-input or fault-injection cases.

areafilesnegativepercent
internal/chaos/report600.0
internal/chaos/web700.0
internal/core/rib900.0
internal/core/stats500.0
internal/plugins/completion500.0
internal/test/mock700.0
internal/component/doctor1218.3
internal/chaos/peer1119.1
internal/component/sysrib1119.1
cmd/ze20210.0

Technique adoption by package age

2 age buckets Within threshold

A technique adopted only forward from its introduction shows here as a step: recent buckets carry it, older ones never do.

If this degrades: Back-fill the oldest bucket, or record the uncovered remainder as tracked backlog (ai/rules/testing.md, Back-Fill New Test Types).

Package first commitPackages with testsWith a fuzz targetWith an RFC-tagged testWith a .ci scenario
20251000
2026489298830

Integrity

When something goes red, does it stop the line?

Logged known-failing tests

1 Needs attention

Reds logged rather than fixed, one shard file per live failure (41 entries archived in plan/known-failures/RESOLVED.md are not counted). Structural gates may never be logged here, but a live entry is not necessarily flaky: some are deterministic product bugs awaiting a fix.

If this degrades: Fix or delete the oldest entry; a permanently logged failure is a deleted test with extra steps.

Test files no `go test` target can build

8 (floor 8) Within threshold

Their build tags are supplied by no go test invocation in Makefile or mk/*.mk, so these tests exist but never run.

If this degrades: Add the tag to a go test invocation, or delete the file. Either way the false inventory shrinks.

FileRequires
cmd/ze/build_tag_appliance_test.goze_appliance, ze_setup
cmd/ze/build_tag_distro_test.goze_appliance, ze_distro, ze_setup
cmd/ze/build_tag_full_test.goze_appliance, ze_distro, ze_setup
cmd/ze/build_tag_setup_test.goze_appliance, ze_distro, ze_setup
cmd/ze/ze_chaos_main_test.goze_chaos
internal/component/config/system/backend_ze_distro_test.goze_distro
internal/component/config/system/selfupdate_test.goze_distro
internal/install/disk/fault_linux_test.goze_installer_fault