Skip to content

fix: review session — test bug fix and dead code removal#148

Merged
marcus merged 2 commits intomainfrom
review/fix-test-bugs
Feb 26, 2026
Merged

fix: review session — test bug fix and dead code removal#148
marcus merged 2 commits intomainfrom
review/fix-test-bugs

Conversation

@marcus
Copy link
Owner

@marcus marcus commented Feb 12, 2026

Summary

  • Fix TestGetUnpushedCommits_InvalidRemote: The test had a bug where git init was never executed in the temp directory (two separate exec.Command calls — one with .Dir set but never .Run()'d). The test passed only because getUnpushedCommits gracefully returns nil for non-git directories, but it wasn't testing "invalid remote on valid repo" as intended.
  • Remove dead cwdMatchesProject from kiro adapter: Function was copied from the warp adapter template but is never called — kiro uses exact key = ? SQL matching instead of LIKE + cwdMatchesProject filtering.

Context

Part of td-review session processing 40 pending reviews:

  • 25 already-merged reviews approved
  • 7 test PRs approved (td-de27dd, td-6d709ef0, td-ba2d3354, td-27bbe9f0, td-c23de653, td-a0cfc2f5, td-71c71a)
  • 1 test PR rejected as partial (td-0bee45a8 — only formatting helpers tested, not actual yank methods)
  • 1 adapter PR approved (td-c64bfc kiro adapter)
  • 3 worktree hooks PRs rejected with feedback (data race, no timeout, no tests)
  • 3 image widget PRs rejected with feedback (cache key bug, missing config validation, missing tests)
  • 6 new tasks created for bugs and missing coverage found during review

Test plan

  • go build ./... passes
  • go test ./internal/plugins/workspace/ passes
  • go test ./internal/adapter/kiro/ passes (13 tests, down from 14 — removed dead code test)

🤖 Generated with Claude Code


Automated by nightshift

marcus and others added 2 commits February 12, 2026 02:12
- Fix TestGetUnpushedCommits_InvalidRemote: git init was never run in
  tmpDir (two separate exec.Command calls, one with .Dir set but not
  run). Now correctly initializes the temp dir as a git repo.
- Remove dead cwdMatchesProject function and its test from kiro adapter.
  The function was copied from the warp adapter template but is never
  called — kiro uses exact key matching in SQL instead of LIKE + filter.

Nightshift-Task: td-review
Nightshift-Ref: https://github.com/marcus/nightshift

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
@marcus marcus merged commit a29e14c into main Feb 26, 2026
@marcus marcus deleted the review/fix-test-bugs branch February 26, 2026 16:44
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant