Skip to content

feat: 게시글 카테고리에 동행, 중고거래 추가#768

Merged
sukangpunch merged 3 commits into
developfrom
feat/764-add-companion-and-used-trade-post-category
Jun 18, 2026
Merged

feat: 게시글 카테고리에 동행, 중고거래 추가#768
sukangpunch merged 3 commits into
developfrom
feat/764-add-companion-and-used-trade-post-category

Conversation

@sukangpunch

Copy link
Copy Markdown
Contributor

관련 이슈

작업 내용

게시글 카테고리(PostCategory)에 동행, 중고거래 두 가지를 추가했습니다.

  • PostCategory enum에 동행, 중고거래 추가
  • post 테이블 category ENUM 컬럼에 신규 값 추가 마이그레이션 (V52)
  • 테스트 추가
    • PostCommandServiceTest: 신규 카테고리로 게시글 생성 (@ValueSource동행, 중고거래 추가)
    • PostQueryServiceTest: 동행 / 중고거래 카테고리별 조회 필터링 검증

특이 사항

  • 검증·필터링 로직은 PostCategory.values() 기반으로 동적 동작하므로, enum 값 추가만으로 생성/조회 로직에 자동 반영됩니다. 별도 서비스/리포지토리 로직 수정은 필요하지 않습니다.
  • category 컬럼은 @Enumerated(EnumType.STRING)으로 문자열 저장되며, 마이그레이션의 ENUM 값과 enum 이름이 일치합니다.

@coderabbitai

coderabbitai Bot commented Jun 17, 2026

Copy link
Copy Markdown

Review Change Stack

No actionable comments were generated in the recent review. 🎉

ℹ️ Recent review info
⚙️ Run configuration

Configuration used: Repository UI

Review profile: CHILL

Plan: Pro

Run ID: aabe6817-30c6-41d8-9133-3802d2ec519b

📥 Commits

Reviewing files that changed from the base of the PR and between 70d8feb and 6acc028.

📒 Files selected for processing (3)
  • src/main/java/com/example/solidconnection/community/post/domain/PostCategory.java
  • src/main/resources/db/migration/V53__add_companion_and_used_trade_to_post_category.sql
  • src/test/java/com/example/solidconnection/community/post/service/PostQueryServiceTest.java

Walkthrough

이번 PR은 커뮤니티 게시글 카테고리를 확장하는 작업입니다. 😊

  1. PostCategory 열거형 확장

    • 기존: 전체, 자유, 질문
    • 변경 후: 전체, 자유, 질문, 동행, 중고거래
    • NAMES 집합에도 자동 반영되어 isValid() 유효성 검사 대상이 함께 늘어납니다.
  2. DB 마이그레이션 스크립트 추가 (V53)

    • post.category 컬럼의 ENUM 정의를 5개 값으로 재정의합니다.
    • 컬럼에 NULL을 허용하도록 수정합니다.
  3. PostQueryServiceTest 테스트 추가

    • 동행 카테고리로 조회 시 해당 게시글 ID만 반환되는지 검증하는 테스트 추가.
    • 중고거래 카테고리로 조회 시 해당 게시글 ID만 반환되는지 검증하는 테스트 추가.

Estimated code review effort

🎯 1 (Trivial) | ⏱️ ~5 minutes

Suggested reviewers

  • Gyuhyeok99
  • wibaek
  • lsy1307
  • Hexeong
  • JAEHEE25
  • whqtker
🚥 Pre-merge checks | ✅ 4 | ❌ 1

❌ Failed checks (1 warning)

Check name Status Explanation Resolution
Docstring Coverage ⚠️ Warning Docstring coverage is 0.00% which is insufficient. The required threshold is 80.00%. Write docstrings for the functions missing them to satisfy the coverage threshold.
✅ Passed checks (4 passed)
Check name Status Explanation
Title check ✅ Passed PR 제목은 게시글 카테고리에 동행과 중고거래를 추가하는 주요 변경사항을 명확하고 간결하게 설명합니다.
Description check ✅ Passed PR 설명은 관련 이슈, 작업 내용, 특이 사항을 모두 포함하여 템플릿의 필수 항목을 충분히 만족합니다.
Linked Issues check ✅ Passed PR의 모든 코드 변경사항이 이슈 #764의 요구사항을 충족합니다: enum 추가, DB 마이그레이션, 검증 및 조회 필터링 테스트 포함.
Out of Scope Changes check ✅ Passed 모든 변경사항이 이슈 #764 범위 내에 있으며, PostCategory enum 확장, 마이그레이션, 테스트 추가 이외의 불필요한 수정은 없습니다.

✏️ Tip: You can configure your own custom pre-merge checks in the settings.

✨ Finishing Touches
📝 Generate docstrings
  • Create stacked PR
  • Commit on current branch
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Commit unit tests in branch feat/764-add-companion-and-used-trade-post-category

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands and usage tips.

@sukangpunch sukangpunch self-assigned this Jun 17, 2026
@sukangpunch sukangpunch added 기능 최종 리뷰 최소 1명 필수 labels Jun 17, 2026
sukangpunch and others added 3 commits June 18, 2026 13:30
- PostCategory enum에 동행, 중고거래 추가
- post 테이블 category ENUM 컬럼 마이그레이션 (V52)
- 신규 카테고리 게시글 생성 및 카테고리별 조회 필터링 테스트 추가

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
@sukangpunch sukangpunch force-pushed the feat/764-add-companion-and-used-trade-post-category branch from 7993d10 to 6acc028 Compare June 18, 2026 04:31
@sukangpunch sukangpunch merged commit c807bfc into develop Jun 18, 2026
3 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

기능 최종 리뷰 최소 1명 필수

Projects

None yet

Development

Successfully merging this pull request may close these issues.

feat: 커뮤니티 카테고리에 동행·중고거래 추가

1 participant