Open
Conversation
added 11 commits
February 2, 2026 15:02
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.
미션 목표
요구사항
Github Actions 활용
Docker 이미지 만들기
다음을 만족하는 Dockerfile과 docker-compose.yaml을 작성해 주세요.
제출 안내
스크린샷
멘토님 리뷰 반영
1️⃣
req.user타입 안전성 보강req.user!단정 사용은 컨트롤러 단에서 안전하지 않을 수 있으니 가드 처리 제안src/controllers/notification-controller.tsunreadCount에서const userId = req.user?.id로 추출userId가 없으면401응답 반환notificationService.countUnread(userId)호출2️⃣ Socket CORS 범위 축소
origin: '*'대신 환경변수 기반 허용 도메인 제한 제안src/socket/io.ts,.env.sampleSOCKET_CORS_ORIGINS(쉼표 구분)를 파싱해 허용 origin 배열 구성BASE_URL,http://localhost:3000,http://localhost:5173) 사용origin: '*'제거 후origin: allowedOrigins적용3️⃣
emitToUser무시 처리 개선emitToUser가 소켓 미초기화 시 조용히 return하지 말고 호출자가 인지 가능하게 예외 처리 제안src/socket/io.tsif (!io) return;if (!io) { throw new Error('Socket.IO server is not initialized'); }4️⃣ 테스트 리셋 전략 개선(
beforeEach resetDb축소)resetDb()를 돌리면 병렬 실행에 불리하므로 개선 필요src/__tests__/article.auth.test.tssrc/__tests__/article.public.test.tssrc/__tests__/product.auth.test.tssrc/__tests__/product.public.test.tssrc/__tests__/auth.test.tsbeforeEach(async () => resetDb())를beforeAll(async () => resetDb())로 변경5️⃣ 서비스 레이어 단위 테스트 보강 (스프린트 9 리뷰)
src/__tests__/article.service.unit.test.ts(신규)articleService.list가 정렬/검색 조건을 저장소로 올바르게 전달하는지 검증order입력 시ValidationError발생 검증npm run -s build통과npm run -s test통과 (총7suite,15tests)5432는 PostgreSQL 포트5555는 Studio 웹 UI 포트(정상 동작)