feat(smartlog): Phase 6 — (no PR) display + full snapshot tests · Closes #309 Closes #308 - #422
Merged
Conversation
#309 Closes #308 ## 무엇 - `render_text` 에 `overlay_requested: bool` 파라미터 추가 - GitHub overlay 가 요청됐지만 열린 PR 이 없는 worktree 에 `├─ (no PR)` 라인 표시 (issue #309 마지막 미충족 acceptance criterion: "PR 없는 worktree는 (no PR) 표시") - PR 이 있는 노드는 기존 PR badge 만 표시 (동작 불변) - `--no-overlay` 모드에서는 (no PR) 표시 안 함 — 조회 자체를 안 했기 때문 - CI overlay 가 있고 PR 이 없는 노드: (no PR) 위에, CI badge 아래에 표시 (순서 보장) ## 테스트 - Phase 6 테스트 4개 추가: - `no_pr_line_shown_when_overlay_requested` — 핵심 경로 - `no_pr_line_suppressed_when_overlay_not_requested` — --no-overlay 격리 - `no_pr_line_plus_ci_badge_for_pr_less_node_with_ci` — Phase 3(#310) 공존 - `no_pr_line_absent_when_pr_overlay_is_set` — PR 있으면 (no PR) 없음 - issue #308 acceptance criterion ("snapshot test >=1") 충족: - `render_text_full_snapshot_single_node_with_pr_and_commit` — 전체 ASCII 골든 출력 - `render_text_full_snapshot_no_pr_no_commits` — (no PR) + 빈 커밋 골든 출력 - 기존 테스트 15개: `render_text(..., false)` → `render_text(..., false, false)` 시그니처 업데이트 ## 다음 Phase 힌트 - #308 / #309 / #310 모두 acceptance criteria 충족 → 이슈 close - v1.0 마일스톤 완료 → 마일스톤 close 검토 Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
This was referenced Sep 4, 2026
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
무엇
parsec smartlog에서 GitHub overlay 가 요청됐으나 열린 PR 이 없는 worktree 에├─ (no PR)라인을 명시적으로 표시합니다 (issue #309 마지막 미충족 acceptance criterion).아울러 issue #308 의 "snapshot test >=1" acceptance criterion 을 full ASCII 골든-출력 비교 테스트로 충족합니다.
왜
변경
핵심 로직 (3줄)
render_text에overlay_requested: bool파라미터 추가.node.pr이None이고overlay_requested == true이면├─ (no PR)라인 emit.새 테스트 (6개)
no_pr_line_shown_when_overlay_requestedno_pr_line_suppressed_when_overlay_not_requestedno_pr_line_plus_ci_badge_for_pr_less_node_with_cino_pr_line_absent_when_pr_overlay_is_setrender_text_full_snapshot_single_node_with_pr_and_commitrender_text_full_snapshot_no_pr_no_commits기존 테스트 15개:
render_text(\u2026, false)→render_text(\u2026, false, false)시그니처 업데이트.다음 Phase 힌트
리스크
LOW — 기존 동작 변화 없음.
overlay_requested=false(=--no-overlay모드) 또는 PR 있는 노드는 일절 영향 없음. 신규 (no PR) 라인은 opt-in (overlay 요청 시에만 출력).롤백
git revert <sha>— 단일 커밋, 파일 1개.Test plan
cargo build --quiet✅cargo fmt --check✅cargo clippy --all-targets -- -D warnings✅cargo test --quiet✅ (238 + 81 + 10 + 5 tests, 0 failed)@erishforG