ainb skill-manager · test coverage

Test coverage matrix & recorded lifecycle demos

38 of 44 skill-manager features (86%) carry at least one automated assertion — 28 via CLI tests, 19 via tmux tripwires (9 on both axes); 6 features remain GAP on both axes (all TUI-only nav / launcher / legend surfaces). Two full lifecycles (CLI + TUI) are captured end-to-end as vhs recordings below.
44
Features tracked
28
CLI test covered
19
tmux tripwire covered
9
Both axes covered
6
GAP on both axes

Coverage matrix

Both CLI + tmux  ·  Partial one axis  ·  GAP neither. Olive cells = covered, clay cells = GAP.

FeatureCLI testtmux tripwireStatus
TUI Screen Layout
Three-pane chrome (Sources/Units/Detail) asserted via screen_opens + sandbox_e2e. No CLI surface — TUI-only. Help-bar keybind legend not separately asserted as a string.
GAPtripwire_core_skill_manager_screen_opens.rsPartial
Discovery Banner
First-open overlay + [Enter] import asserted live. [d] details-toggle and [s] skip-with-persistence are NOT asserted (only [Enter] import path is).
GAPtripwire_core_skill_manager_discovery_banner.rsPartial
[i] Add Source Keybind
keys_wired presses [i], types a colon-bearing URI, Enter, asserts source lands in manifest.yaml. CLI side via source_cli_tests (ainb source add).
source_cli_tests.rstripwire_core_skill_manager_keys_wired.rsBoth
[u] Update Keybind
CLI path (ainb skill update) well covered. No tmux tripwire presses [u] in-screen — only the underlying CLI flow is tested.
skill_update_tests.rsGAPPartial
[c] Check Keybind
keys_wired doc-comment mentions [c] but only [i] and [/] are actually asserted. No tmux tripwire presses [c] to re-trigger a drift scan. CLI ainb skill check covered.
skill_check_tests.rsGAPPartial
[r] Remove Keybind
CLI path (ainb skill remove) covered. No tmux tripwire presses [r] in-screen.
skill_remove_tests.rsGAPPartial
[s] Sync Keybind (No Conflict)
s_routes_to_sync_live presses [s] on a non-shadowed unit, asserts SkillManagerSync + 'sync: <unit>' notification.
skill_sync_tests.rstripwire_core_skill_manager_s_routes_to_sync_live.rsBoth
[s] Conflict Flip Keybind
conflict_flip presses [s] on a shadowed_by pair, asserts manifest edge flips + idempotent roundtrip + no-op on non-conflict. No CLI equivalent for the flip routing.
GAPtripwire_core_skill_manager_conflict_flip.rsPartial
[/] Search Keybind
keys_wired presses [/], filters Units table case-insensitively, guards the ':' palette regression. search_cli_tests covers the CLI search surface.
search_cli_tests.rstripwire_core_skill_manager_keys_wired.rsBoth
[m] Refresh Discovery Keybind
GAP both axes. All tripwires use [m] from HOME to OPEN the screen, never as the in-screen refresh-discovery key that clears .discovery-skipped. The marker-clearing/force-rebanner behavior is unasserted.
GAPGAPGAP
Arrow/j/k Navigation
GAP. No tripwire presses arrow/j/k to move selection and recompute Detail. TUI-only feature with no nav tripwire and no CLI surface.
GAPGAPGAP
Home/g / End/G Navigation
GAP both axes. First/last jump nav is entirely unasserted in tmux and has no CLI surface.
GAPGAPGAP
Discovery Class-A Walker
class_a_walker_tests (CLI crate) covers marketplace cache scan + URI synthesis. No dedicated tmux tripwire (banner test exercises it indirectly via reconciler output).
class_a_walker_tests.rsGAPPartial
Discovery Class-C Walker
discover_tests covers orphan-unit scan across adapter homes. No dedicated tmux tripwire; only the merged reconciler output surfaces in the banner test.
discover_tests.rsGAPPartial
Discovery Reconciler
discover_tests exercises Class-A+Class-C merge / orphan-wins / shadowed_by. discovery_banner asserts the banner counts equal reconciler output live.
discover_tests.rstripwire_core_skill_manager_discovery_banner.rsBoth
Drift Detection Column
drift_column (TestBackend) renders all glyph/colour combos incl '…' placeholder. drift_glyph_live also covers ⚠ live. No CLI column rendering (CLI check is tabular text).
GAPtripwire_core_skill_manager_drift_column.rsPartial
Background Drift Poll
drift_background_poll asserts GoToSkillManager spawns poll, lands in drift_cache on next tick, coalesces in-flight. Mocked backend. No CLI surface.
GAPtripwire_core_skill_manager_drift_background_poll.rsPartial
Drift GitLsRemoteBackend
drift_tests_integration covers InSync/Outdated/argv-smuggle/GIT_TERMINAL_PROMPT against real bare repo. drift_glyph_live proves it end-to-end in the live binary.
drift_tests_integration.rstripwire_core_skill_manager_drift_glyph_live.rsBoth
Skill Usage Tracking
lockfile_tests covers schema-v2 LockedUnit.usage round-trip. usage_renders (TestBackend) + usage_renders_live assert Detail-pane rendering.
lockfile_tests.rstripwire_core_skill_manager_usage_renders.rsBoth
ainb skill usage CLI
skill_usage_tests seeds fake session-log JSONL + asserts lockfile usage refresh. detect_invocations covers the parser. No tmux surface for the CLI command itself.
skill_usage_tests.rsGAPPartial
Detail Pane Render
usage_renders + usage_renders_live assert URI/usage/time-ago in Detail pane. format_time_ago fallback covered. TUI-only, no CLI.
GAPtripwire_core_skill_manager_usage_renders.rsPartial
[s] Sync to Home Executor
sync_to_home_tests (core) verifies bytes land at mapped home path idempotently via ContentFetcher. No tmux tripwire isolates the to-home executor; s_routes_to_sync only asserts routing.
sync_to_home_tests.rsGAPPartial
[s] Sync to Repo Executor
sync_to_repo_tests + skill_sync_roundtrip_tests cover home→repo copy/commit/push idempotency + argv hardening. No tmux tripwire for the to-repo executor.
sync_to_repo_tests.rsGAPPartial
Sync SyncPlanner
sync_tests covers plan_sync ToRepo/ToHome/NoOp decision logic (pure fn). No TUI tripwire; not a user-visible surface on its own.
sync_tests.rsGAPPartial
ainb skill sync CLI
skill_sync_roundtrip_tests + skill_sync_tests cover --to-repo/--to-home/--dry-run end-to-end against git sources. No tmux surface for the CLI command.
skill_sync_roundtrip_tests.rsGAPPartial
Auto-infer target_layout
auto_infer_gh_layout_tests covers gh:owner/repo fall-through to BOOTSTRAP_DEFAULT_MAPPINGS. mapping_tests covers resolve_pair. Pure-fn, no TUI surface.
auto_infer_gh_layout_tests.rsGAPPartial
ainb skill check CLI
skill_check_tests covers tabular output, --json variant, per-source scoping with MockBackend. No tmux surface for the CLI command.
skill_check_tests.rsGAPPartial
ainb skill promote Command
promote_tests drives full local:->git: flow against hermetic bare repo (file://): bare-repo receives skills/, manifest URI rewritten, lockfile sha256. No TUI/tmux surface — promote is CLI-only.
promote_tests.rsGAPPartial
Promote Pre-flight Checks
Covered within promote_tests (gh auth / manifest-has-unit / local: / defaultBranchRef resolution, fail-fast before writes). No tmux surface.
promote_tests.rsGAPPartial
Promote Failure Modes
promote_tests is the only home; verify it asserts each failure branch (auth fail, push fail leaves manifest unrewritten, network down). No tmux surface.
promote_tests.rsGAPPartial
Promote Cache Persistence
Clone-once/reuse-via-pull cache layout exercised inside promote_tests. No dedicated persistence-across-runs assertion called out; no tmux surface.
promote_tests.rsGAPPartial
Sandbox Test Fixture (Minimal Tier)
sandbox_fixture_smoke asserts minimal-tier build + seeded skills. sandbox_loads renders it via TestBackend.
sandbox_fixture_smoke.rstripwire_core_skill_manager_sandbox_loads.rsBoth
Sandbox Test Fixture (Full Tier)
sandbox_fixture_smoke covers both tiers building correctly. sandbox_e2e exercises the full-tier fixture in the live binary.
sandbox_fixture_smoke.rstripwire_core_skill_manager_sandbox_e2e.rsBoth
Sandbox Rust API
sandbox_fixture_smoke covers build_skill_manager_sandbox / env_vars round-trip / refuse-$HOME / idempotent rebuild. API-level, no TUI surface.
sandbox_fixture_smoke.rsGAPPartial
Sandbox Bash Launcher
GAP both axes. scripts/skill-manager-sandbox.sh (up/down, safety guards, .ainb-sandbox-marker) exists but has no automated test — exercised only by hand.
GAPGAPGAP
Sandbox Just Recipes
GAP both axes. skill-manager.just module (up/tui/cli/inspect/down) exists but is untested in CI; only manually invoked.
GAPGAPGAP
Dotdir Strip Fix
sync_strip_tool_dotdir_test is the dedicated regression for strip_tool_dotdir() in apply_to_home/repo. Pure-fn, no TUI surface.
sync_strip_tool_dotdir_test.rsGAPPartial
Per-Source Advisory Lock
concurrent_sync_test verifies the .ainb-sync.lock advisory lock prevents git-index contention across units. No TUI surface.
concurrent_sync_test.rsGAPPartial
Input State Modal
keys_wired exercises InputState for both AddSource ([i]) and Search ([/]) — keystroke-to-buffer until Enter/Esc, centered overlay. No CLI surface.
GAPtripwire_core_skill_manager_keys_wired.rsPartial
Selected Unit Conflict Peer Check
conflict_flip + s_routes_to_sync_live together prove the manifest-read routing (sync vs flip) based on shadowed_by peer. No CLI surface.
GAPtripwire_core_skill_manager_conflict_flip.rsPartial
Visible Indices Singleton
keys_wired [/] filter proves visible_indices() drives render+filter agreement (Units empties, Detail keeps name). Nav-side of the singleton (selection movement) is NOT separately asserted.
GAPtripwire_core_skill_manager_keys_wired.rsPartial
CLI run_skill_cli / run_source_cli Helpers
In-process dispatch + notification capture proven by keys_wired ([i] -> manifest write) and s_routes_to_sync_live (notification surfaces). source_cli_tests covers the dispatch path directly.
source_cli_tests.rstripwire_core_skill_manager_keys_wired.rsBoth
SkillsScreenData Live Data Binding
screen_opens asserts Manifest+Lockfile+UsageCache populate Sources/Units/Detail on GoToSkillManager. sandbox_loads complements in-process. No CLI surface.
GAPtripwire_core_skill_manager_screen_opens.rsPartial
Help Bar Keybinds
GAP both axes. The advertised legend string ([i][u][c][r][s][/][?][q] with action names + gold/muted styling) is never asserted as a rendered string; individual key wiring is tested but not the legend itself.
GAPGAPGAP

Gaps (14)

Recorded lifecycle demos

CLI lifecycle

source add → source list → skill install (9 tools) → skill check / --json → edit deployed SKILL.md → skill check --json → skill sync --to-repo --dry-run → skill remove --yes → ls confirms removal. Recorded on a fresh minimal-tier sandbox at /tmp/sm-rec-cli-lifecycle; binary ainb 1.2.1 built under real HOME.

CLI lifecycle recorded demo

recordings/cli-lifecycle.gif

TUI lifecycle

m (open Skill Manager) → Down ×2 (navigate Units, recompute Detail) → / commit (search filter) → Esc (clear) → s (sync selected unit) → q (return to HomeScreen). Recorded on a full-tier sandbox at /tmp/sm-rec-tui-lifecycle; Dracula theme, 1400×800, ainb 1.2.1.

TUI lifecycle recorded demo

recordings/tui-lifecycle.gif

Generated from the skill-manager coverage audit. 2 of 2 recordings embedded as GIF. GIFs were produced with vhs against the real ainb 1.2.1 binary in isolated sandboxes (/tmp/sm-rec-cli-lifecycle, /tmp/sm-rec-tui-lifecycle), torn down after capture. No fabricated data — every test name above maps to a real file on feat/skill-manager.