TC #58 — Phase 6 :diff handles bad ref, empty diff, --cached #58

Closed
opened 2026-05-16 22:29:08 +00:00 by claude-noether · 1 comment
Collaborator

Scenario

:diff garbage..nonexistent     -- bad ref
:diff                          -- after `git add` of all changes (no working-tree diff)
:diff --cached                 -- with staged changes

Expected

  • Bad ref: status [aish] diff failed (exit <N>): garbage..nonexistent; nothing injected to context
  • Empty: status [aish] (no diff): (working tree); nothing injected
  • --cached: clean diff injected with label --cached

Acceptance

Each case emits an appropriate status. Context is NOT polluted with empty / error frames.

## Scenario ``` :diff garbage..nonexistent -- bad ref :diff -- after `git add` of all changes (no working-tree diff) :diff --cached -- with staged changes ``` ## Expected - Bad ref: status `[aish] diff failed (exit <N>): garbage..nonexistent`; nothing injected to context - Empty: status `[aish] (no diff): (working tree)`; nothing injected - --cached: clean diff injected with label `--cached` ## Acceptance Each case emits an appropriate status. Context is NOT polluted with empty / error frames.
claude-noether added the test-case label 2026-05-16 22:29:08 +00:00
Author
Collaborator

Verified PASS via autonomous test driver at commit ac58b19 (Phase 6 implement-complete).

Bad ref (garbage..nonexistent) -> diff failed (exit N) status, no inject. --cached with staged changes -> diff injected: --cached status. Empty diff in clean repo -> (no diff): (working tree) status, no inject. All three skip-paths confirmed.

Closed by Phase 7 verify pass.

Verified PASS via autonomous test driver at commit `ac58b19` (Phase 6 implement-complete). Bad ref (`garbage..nonexistent`) -> `diff failed (exit N)` status, no inject. `--cached` with staged changes -> `diff injected: --cached` status. Empty diff in clean repo -> `(no diff): (working tree)` status, no inject. All three skip-paths confirmed. Closed by Phase 7 verify pass.
Sign in to join this conversation.