Skip to content

test(cli): root and dry-run tests use the public interface - #3930

Merged
dan-petty merged 5 commits into
mainfrom
test/1333-root-and-dry-run-tests-on-edge-fakes
Nov 7, 2026
Merged

dan-petty merged 5 commits into
mainfrom
test/1333-root-and-dry-run-tests-on-edge-fakes

Conversation

@dan-petty

Copy link
Copy Markdown
Owner

The tests of the root module and of the dry-run package now use the public interface. They run real commands through the cli fixture. The process fake shows which programs a command starts. No test patches a devops_cli name or imports a private name.

Each test file now covers one behavior. The tests that held several behaviors are split. The change touches no code under src/.

Closes #3901

Change: openspec/changes/archive/2026-11-07-3901-root-and-dry-run-tests-on-edge-fakes/

@dan-petty dan-petty added type/test Type test: a new or changed test scope/cli Core CLI framework, Typer subcommands, options, and tables labels Nov 7, 2026
@dan-petty

Copy link
Copy Markdown
Owner Author

Test and check results:

  • Full uv run devops ci on the final code: pass (exit 0, 13m 53s).
  • Focused run after the rebase (entry point, global dry run, passthrough, dry_run package, hermetic floor): 75 passed.
  • Review fixes: a new test for in_dry_run_invocation(), and the k8s configure-urls --stack logging case now checks the stack-specific output.

The tests of main.py, entry.py and dry_run/ run real commands through the cli fixture and the process fake. They patch no devops_cli name and import no private name. The three old files are split by behavior.

Plans #3901 as an OpenSpec change.
@dan-petty
dan-petty force-pushed the test/1333-root-and-dry-run-tests-on-edge-fakes branch from 22ba442 to d1744bd Compare November 7, 2026 04:27
@dan-petty

Copy link
Copy Markdown
Owner Author

First CI run failed in one case: sandbox deploy --dry-run took the runner checkout (under /home) as its workspace. The test now runs in a temporary directory. The new head passes all checks.

@dan-petty
dan-petty marked this pull request as ready for review November 7, 2026 04:33
@dan-petty
dan-petty merged commit ed0fac6 into main Nov 7, 2026
23 checks passed
@dan-petty
dan-petty deleted the test/1333-root-and-dry-run-tests-on-edge-fakes branch November 7, 2026 04:33
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

scope/cli Core CLI framework, Typer subcommands, options, and tables type/test Type test: a new or changed test

Projects

None yet

Development

Successfully merging this pull request may close these issues.

test(cli): root module and dry-run tests use the public interface

1 participant