banger/internal/cli
Thales Maciel c42fcbe012
cli + daemon: move test seams off package globals onto injected structs
CLI: introduce internal/cli.deps which owns every RPC/SSH/host-command
seam the tree used to reach through mutable package vars. Command
builders, orchestrators, and the completion helpers become methods on
*deps. Tests construct their own deps per case, so fakes no longer leak
across cases and tests are free to run in parallel.

Daemon: move workspaceInspectRepoFunc + workspaceImportFunc onto the
Daemon struct (workspaceInspectRepo / workspaceImport), mirroring the
existing guestWaitForSSH / guestDial pattern. Workspace-prepare tests
drop t.Parallel() guards now that they no longer mutate process-wide
state.

Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
2026-04-19 19:03:55 -03:00
..
aliases_test.go cli QoL: vm prune, list→ls aliases, delete→rm aliases 2026-04-19 12:17:46 -03:00
banger.go cli + daemon: move test seams off package globals onto injected structs 2026-04-19 19:03:55 -03:00
bangerd.go Add Go daemon-driven VM control plane 2026-03-16 12:52:54 -03:00
cli_test.go cli + daemon: move test seams off package globals onto injected structs 2026-04-19 19:03:55 -03:00
commands_daemon.go cli + daemon: move test seams off package globals onto injected structs 2026-04-19 19:03:55 -03:00
commands_image.go cli + daemon: move test seams off package globals onto injected structs 2026-04-19 19:03:55 -03:00
commands_internal.go cli + daemon: move test seams off package globals onto injected structs 2026-04-19 19:03:55 -03:00
commands_kernel.go cli + daemon: move test seams off package globals onto injected structs 2026-04-19 19:03:55 -03:00
commands_vm.go cli + daemon: move test seams off package globals onto injected structs 2026-04-19 19:03:55 -03:00
commands_vm_session.go cli + daemon: move test seams off package globals onto injected structs 2026-04-19 19:03:55 -03:00
completion.go cli + daemon: move test seams off package globals onto injected structs 2026-04-19 19:03:55 -03:00
completion_test.go cli + daemon: move test seams off package globals onto injected structs 2026-04-19 19:03:55 -03:00
daemon_lifecycle.go cli + daemon: move test seams off package globals onto injected structs 2026-04-19 19:03:55 -03:00
deps.go cli + daemon: move test seams off package globals onto injected structs 2026-04-19 19:03:55 -03:00
formatters_test.go coverage: easy-wins batch across cli, system, paths, vmdns, toolingplan 2026-04-18 17:57:05 -03:00
make_bundle_test.go banger internal make-bundle: build image bundles from flat rootfs tars 2026-04-17 15:17:50 -03:00
printers.go cli: split banger.go god file into focused files 2026-04-19 17:34:32 -03:00
prune_test.go cli + daemon: move test seams off package globals onto injected structs 2026-04-19 19:03:55 -03:00
ssh.go cli + daemon: move test seams off package globals onto injected structs 2026-04-19 19:03:55 -03:00
vm_create.go cli + daemon: move test seams off package globals onto injected structs 2026-04-19 19:03:55 -03:00
vm_run.go cli + daemon: move test seams off package globals onto injected structs 2026-04-19 19:03:55 -03:00
vm_spec_test.go vm defaults: host-aware sizing + spec line on spawn + doctor check 2026-04-19 13:06:51 -03:00