Skip to content

[Test] recruitment admin CRUD 테스트#173

Merged
seoyeon83 merged 5 commits into
devfrom
test/#136-recruitment-admin-crud
Jun 25, 2026
Merged

[Test] recruitment admin CRUD 테스트#173
seoyeon83 merged 5 commits into
devfrom
test/#136-recruitment-admin-crud

Conversation

@seoyeon83

Copy link
Copy Markdown
Member

💡 개요

Recruitment 도메인 테스트 중 Admin 모집 공고/질문 CRUD (REC-ADMIN-002~009) 테스트를 추가합니다. dev 최신(#170 평가 도메인 포함)을 머지한 상태라, 추가 테스트가 현재 코드 기준으로 컴파일·통과함을 확인했습니다.

🪐 주요 변경 사항

✅ 상세 내용

  • Service(Unit): 각 기능 정상/예외(중복·검증·NOT_FOUND) + JsonNullable null(삭제)/undefined(유지) 분기
  • Controller(@WebMvcTest): 정상 응답 + @Valid/@NotEmpty/@positive + 401/403
  • Integration(Testcontainers): 등록·삭제 end-to-end, 질문 다건 등록 부분 실패 전체 롤백(원자성)
  • Repository(@DataJpaTest): findAllByOrderByTermDesc, label/order_num 중복 쿼리 등
  • recruitment 도메인 전 기능(공개 8 + 어드민 12) 테스트 누락 0건 확인

🔔 참고 사항

  • @coderabbitai ignore — 본 PR은 CodeRabbit 리뷰 제외
  • dev는 CD 미트리거(배포 영향 없음). 머지 후 CI로 통합 검증
  • 테스트 명세서(docs/test/TC-REC-ADMIN-006.md)에 TC-006b 동기화 (docs는 gitignore라 PR 미포함)

- Service: 공고/질문 CRUD 39개 (Given-When-Then, Mockito)
- Controller: @WebMvcTest 정상/예외/Valid/Security 38개
- Integration: @SpringBootTest Testcontainers 13개
- Repository: existsByRecruitmentId 등 파생 쿼리 보강
- createRecruitment: end < start 케이스 추가 (== 외)
- createQuestions: TABLE metadata 누락 → MISSING_PARAMETER 분기
- updateRecruitment/updateQuestion: JsonNullable undefined→기존 유지 전용 케이스
- Controller: item @positive(order_num) @Valid cascade 위반 → 400
- Integration: 다건 등록 2번째 충돌 시 전체 미저장(원자성) 검증
- CreateQuestions TABLE metadata 누락: TC-008 → TC-007b (기존 TC-008=multiple과 충돌 회피)
- Controller order_num @positive: EX-002 → TC-009b (기존 EX-002=limit_length와 충돌 회피)
@seoyeon83
seoyeon83 merged commit e6cda58 into dev Jun 25, 2026
2 checks passed
@seoyeon83 seoyeon83 changed the title #136 recruitment admin CRUD 테스트 (REC-ADMIN-002~009) [Test] recruitment admin CRUD 테스트 Jun 25, 2026
@seoyeon83 seoyeon83 self-assigned this Jun 25, 2026
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