[refactor/#396] User aggregate 도메인 규칙 안전망 정리#402
Merged
Conversation
서비스 테스트에만 의존하던 User aggregate 규칙을 전용 도메인 테스트로 고정해 이후 User Account 리팩터링에서 상태 전이와 익명화 회귀를 빠르게 감지할 수 있게 했다. Constraint: #396은 구조 변경보다 User aggregate 규칙 안전망 확보가 우선이었다 Rejected: 관심사 불변식 이동까지 같은 커밋에 포함 | #397 범위와 섞여 책임이 흐려져 보류 Confidence: high Scope-risk: narrow Directive: 이후 #399/#397/#398 작업은 UserTest를 유지한 채 패키지 재배치와 aggregate 책임 이동을 진행할 것 Tested: ./gradlew test --tests 'com.techfork.domain.useraccount.entity.UserTest' --tests 'com.techfork.domain.useraccount.service.UserCommandServiceTest' --tests 'com.techfork.domain.useraccount.service.UserQueryServiceTest' -PexcludeIntegration; ./gradlew test -PexcludeIntegration Not-tested: ./gradlew integrationTest; ./gradlew evaluationTest; ./gradlew evaluationSetup
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.
❤️ 기능 설명
Useraggregate의 핵심 상태 전이 규칙을 전용 도메인 테스트UserTest로 고정했습니다.createSocialUser()기본 상태PENDING, 기본 역할ROLE_USERupdateUser()이후ACTIVEupdateProfile()는 전달된 필드만 수정withdraw()시 개인정보 null 처리 +WITHDRAWNreactivate()시PENDING복귀 + 이메일/프로필 이미지 복구./gradlew test --tests 'com.techfork.domain.useraccount.entity.UserTest' --tests 'com.techfork.domain.useraccount.service.UserCommandServiceTest' --tests 'com.techfork.domain.useraccount.service.UserQueryServiceTest' -PexcludeIntegration✅./gradlew test -PexcludeIntegration✅연결된 issue
연결된 issue를 자동으로 닫기 위해 아래 {이슈넘버}를 입력해주세요.
close #396
✅ 체크리스트