Skip to content

[#400] 위젯 예외 케이스 테스트를 보강한다#405

Merged
opficdev merged 3 commits intodevelopfrom
test/#400-widget-exception-test
May 1, 2026
Merged

[#400] 위젯 예외 케이스 테스트를 보강한다#405
opficdev merged 3 commits intodevelopfrom
test/#400-widget-exception-test

Conversation

@opficdev
Copy link
Copy Markdown
Owner

@opficdev opficdev commented May 1, 2026

🔗 연관된 이슈

📝 작업 내용

📌 요약

  • 위젯 스냅샷 생성 로직의 날짜 경계 예외 케이스 검증 추가
  • Heatmap placeholder의 실제 월 배치 기반 표시 구조 적용
  • 위젯 설정값과 동기화 실패 상황에 대한 테스트 보강

🔍 상세

  • Heatmap 위젯 스냅샷의 분기 시작일 포함 및 다음 분기 시작일 제외 검증
  • Q4 분기에서 다음 해 1월 데이터가 제외되는지 검증
  • Today 위젯 스냅샷의 overdue, dueSoon, later, unscheduled 날짜 경계 검증
  • Heatmap placeholder가 고정 주차 수가 아닌 실제 월별 날짜 위치를 사용하도록 변경
  • 깨진 위젯 설정값에 대한 기본값 fallback 검증
  • Today/Heatmap 스냅샷 갱신 중 한쪽 실패가 다른 위젯 갱신을 막지 않는지 검증
  • 공용 Calendar.startOfQuarter(for:) extension 위치를 WidgetShared로 이동

📸 영상 / 이미지 (Optional)

image image
systemSmall systemMedium
image
테스트 코드 결과

Copy link
Copy Markdown
Contributor

@gemini-code-assist gemini-code-assist Bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Code Review

이번 pull request는 위젯의 히트맵 placeholder 로직을 개선하고, 관련 단위 테스트들을 추가하여 안정성을 높였습니다. 특히 WidgetHeatmapPlaceholderShape를 도입하여 실제 날짜 위치에 기반한 placeholder를 생성하도록 변경되었습니다. 리뷰 결과, 테스트 코드의 중복을 줄이기 위한 fixture 개선과 placeholder 구현 시 가짜 데이터 모델 대신 메인 레이아웃 로직을 공유하도록 하는 구조적 개선 사항이 제안되었습니다.

Comment thread DevLog_Unit/Widget/WidgetSnapshotPreferenceStoreTests.swift Outdated
Comment thread WidgetShared/WidgetHeatmapPlaceholderShape.swift
@opficdev opficdev self-assigned this May 1, 2026
@opficdev opficdev added the qa TestFlight에 배포 label May 1, 2026
@opficdev opficdev merged commit 1998151 into develop May 1, 2026
1 check passed
@opficdev opficdev deleted the test/#400-widget-exception-test branch May 1, 2026 02:44
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

qa TestFlight에 배포

Projects

None yet

Development

Successfully merging this pull request may close these issues.

위젯 예외 처리와 테스트를 보강한다

1 participant