테스트 목록 - KimGyuBek/Threadly GitHub Wiki

Threadly 전체 테스트 목록


목차


요약

항목 threadly-service notification-service 전체
테스트 클래스 111 31 142
테스트 메서드 531 164 695
  • threadly-service 모듈 수: 9
  • notification-service 모듈 수: 10

threadly-service 요약

모듈 테스트 클래스 수 테스트 메서드 수 주요 검증 영역
adapter-kafka 1 6 Kafka 에러 핸들링
adapter-persistence 15 68 JPA Persistence 어댑터
adapter-redis 5 27 Redis 캐시/토큰
adapter-storage 1 6 로컬 이미지 스토리지
app-api 46 230 REST API 통합
app-batch 6 20 배치 작업/스케줄링
core-domain 5 33 도메인 객체 로직
core-service 27 110 서비스 계층 비즈니스
threadly-commons 5 31 공통 유틸리티
총계 111 531 -

notification-service 요약

모듈 테스트 클래스 수 테스트 메서드 수 주요 검증 영역
notification-commons 3 12 JWT·응답 공통 유틸
core-domain 1 2 알림 도메인 로직
core-port 1 2 커서 기반 DTO
core-service 7 32 알림/메일 서비스 레이어 검증
adapter-redis 1 7 블랙리스트 토큰 조회
adapter-kafka 2 4 Kafka Consumer 입력 검증
adapter-persistence 2 6 MongoDB 어댑터 CRUD
adapter-smtp 2 3 SMTP 메일 전송 위임
adapter-websocket 2 6 실시간 푸시 전송/세션 관리
app-api 10 90 알림 REST API 통합
총계 31 164 -

전체 통계

  • 총 테스트 클래스: 142개
  • 총 테스트 메서드: 695개
  • 사용 프레임워크: JUnit 5, Spring Boot Test, Mockito, AssertJ
  • 통합 테스트 인프라: PostgreSQL, Redis, MongoDB, Kafka, Spring Batch

프로젝트별 상세 목록

threadly-service

모듈 테스트 클래스 수 테스트 메서드 수
adapter-kafka 1 6
adapter-persistence 15 68
adapter-redis 5 27
adapter-storage 1 6
app-api 46 230
app-batch 6 20
core-domain 5 33
core-service 27 110
threadly-commons 5 31
adapter-kafka · 테스트 클래스 1개 · 테스트 메서드 6개

KafkaErrorHandlerTest

테스트 메서드 시나리오
successCallback_shouldBeCreatedSuccessfully successCallback 테스트
successCallback_shouldNotThrowException_whenExecuted successCallback - 실행 시 예외가 발생하지 않아야 한다
failureCallback_shouldBeCreatedSuccessfully failureCallback 테스트
failureCallback_shouldNotThrowException_whenExecuted failureCallback - 실행 시 예외가 발생하지 않아야 한다
failureCallback_shouldHandleVariousExceptionTypes failureCallback - 다양한 예외 타입을 처리할 수 있어야 한다
callbacks_shouldBeCreatedWithSameEventId 콜백 동시 사용 테스트
adapter-persistence · 테스트 클래스 15개 · 테스트 메서드 68개

CommentLikeMapperTest

테스트 메서드 시나리오
toDomain_shouldConvertEntityToDomain CommentLikeEntity -> CommentLike Domain
toEntity_shouldConvertDomainToEntity CommentLike Domain -> CommentLikeEntity

FollowMapperTest

테스트 메서드 시나리오
toEntity_shouldConvertDomainToEntity Follow Domain -> FollowEntity
toDomain_shouldConvertEntityToDomain FollowEntity -> Follow Domain

FollowPersistenceAdapterTest

테스트 메서드 시나리오
createFollow_shouldCreateFollow_whenValid 팔로우 생성 테스트
isFollowing_shouldReturnTrue_whenFollowExists 팔로우 여부 확인 테스트
isFollowing_shouldReturnFalse_whenFollowDoesNotExist 2. 팔로우 관계가 없으면 false를 반환한다
findFollowStatusType_shouldReturnStatus_whenFollowExists 팔로우 상태 조회 테스트
findFollowStatusType_shouldReturnEmpty_whenFollowDoesNotExist 실패
updateFollowStatus_shouldUpdateStatus_whenFollowExists 팔로우 상태 업데이트 테스트
deleteFollow_shouldDelete_whenFollowExists 팔로우 삭제 테스트
existsByFollowerIdAndFollowingIdAndStatusType_shouldReturnTrue_whenExists 특정 상태의 팔로우 존재 여부 확인 테스트
existsByFollowerIdAndFollowingIdAndStatusType_shouldReturnFalse_whenNotExists 2. 특정 상태의 팔로우가 존재하지 않으면 false를 반환한다
deleteByFollowerIdAndFollowingIdAndStatusType_shouldDelete_whenExists 특정 상태의 팔로우 삭제 테스트

PostCommentMapperTest

테스트 메서드 시나리오
toDomain_shouldConvertEntityToDomain PostCommentEntity -> PostComment Domain
toDomain_shouldThrowException_whenEntityIsNull PostCommentEntity가 null이면 예외를 던진다
toEntity_shouldConvertDomainToEntity PostComment Domain -> PostCommentEntity

PostCommentPersistenceAdapterTest

테스트 메서드 시나리오
savePostComment_shouldSaveComment_whenValid 댓글 저장 테스트
fetchById_shouldReturnComment_whenCommentExists 댓글 ID로 조회 테스트
fetchById_shouldReturnEmpty_whenCommentDoesNotExist 실패
updatePostCommentStatus_shouldUpdateStatus_whenCommentExists 댓글 상태 변경 테스트
fetchCommentStatus_shouldReturnStatus_whenCommentExists 댓글 상태 조회 테스트
fetchCommentStatus_shouldReturnEmpty_whenCommentDoesNotExist 실패
updateAllCommentStatusByPostId_shouldUpdateAll_whenCommentsExist 게시글의 모든 댓글 상태 변경 테스트

PostImageMapperTest

테스트 메서드 시나리오
toEntity_shouldConvertDomainToEntity PostImage Domain -> PostImageEntity
toEntity_shouldConvertMultipleImages 여러 이미지 순서로 PostImage를 PostImageEntity로 변환한다

PostLikeMapperTest

테스트 메서드 시나리오
toDomain_shouldConvertEntityToDomain PostLikeEntity -> PostLike Domain
toEntity_shouldConvertDomainToEntity PostLike Domain -> PostLikeEntity

PostLikePersistenceAdapterTest

테스트 메서드 시나리오
createPostLike_shouldCreateLike_whenValid 게시글 좋아요 생성 테스트
existsByPostIdAndUserId_shouldReturnTrue_whenLikeExists 게시글 좋아요 존재 여부 확인 테스트
existsByPostIdAndUserId_shouldReturnFalse_whenLikeDoesNotExist 2. 존재하지 않는 좋아요의 경우 false를 반환한다
fetchLikeCountByPostId_shouldReturnCount_whenLikesExist 게시글별 좋아요 개수 조회 테스트
fetchLikeCountByPostId_shouldReturnZero_whenNoLikes 2. 좋아요가 없는 게시글의 경우 0을 반환한다
deleteByPostIdAndUserId_shouldDelete_whenLikeExists 게시글 좋아요 삭제 테스트
deleteByPostIdAndUserId_shouldReturnZero_whenLikeDoesNotExist 2. 존재하지 않는 좋아요 삭제 시 0을 반환한다
deleteAllByPostId_shouldDeleteAll_whenLikesExist 게시글의 모든 좋아요 삭제 테스트

PostMapperTest

테스트 메서드 시나리오
toDomain_shouldConvertEntityToDomain PostEntity -> Post Domain
toDomain_shouldThrowException_whenEntityIsNull PostEntity가 null이면 예외를 던진다
toEntity_shouldConvertDomainToEntity Post Domain -> PostEntity

PostPersistenceAdapterTest

테스트 메서드 시나리오
savePost_shouldReturnPostId_whenPostIsValid 게시글 저장 테스트
fetchById_shouldReturnPost_whenPostIdExists 게시글 ID로 조회 테스트
fetchById_shouldReturnEmpty_whenPostIdDoesNotExist 실패
updatePost_shouldUpdateContent_whenPostExists 게시글 수정 테스트
changeStatus_shouldUpdateStatus_whenPostExists 게시글 상태 변경 테스트
existsById_shouldReturnTrue_whenPostExists 게시글 존재 여부 확인 테스트
existsById_shouldReturnFalse_whenPostDoesNotExist 2. 존재하지 않는 게시글의 경우 false를 반환한다
increaseViewCount_shouldIncreaseByOne_whenPostExists 게시글 조회수 증가 테스트
fetchUserIdByPostId_shouldReturnUserId_whenPostExists 게시글 작성자 조회 테스트
fetchUserIdByPostId_shouldReturnEmpty_whenPostDoesNotExist 실패

UserMapperTest

테스트 메서드 시나리오
toDomain_shouldConvertEntityToDomain UserEntity -> User Domain
toEntity_shouldConvertDomainToEntity User Domain -> UserEntity

UserPersistenceAdapterTest

테스트 메서드 시나리오
saveUser_shouldReturnUserId_whenUserIsValid 사용자 저장 테스트
findByEmail_shouldReturnUser_whenEmailExists 이메일로 사용자 조회 테스트
findByEmail_shouldReturnEmpty_whenEmailDoesNotExist 실패
findByUserId_shouldReturnUser_whenUserIdExists 사용자 ID로 조회 테스트
findByUserId_shouldReturnEmpty_whenUserIdDoesNotExist 실패
updateEmailVerification_shouldUpdateStatus_whenUserExists 이메일 인증 상태 업데이트 테스트
updateUserStatus_shouldChangeStatus_whenUserExists 사용자 상태 업데이트 테스트

UserProfileImageMapperTest

테스트 메서드 시나리오
toEntity_shouldConvertDomainToEntity UserProfileImage Domain -> UserProfileImageEntity
toDomain_shouldConvertEntityToDomain UserProfileImageEntity -> UserProfileImage Domain

UserProfileMapperTest

테스트 메서드 시나리오
toDomain_shouldConvertEntityToDomain UserProfileEntity -> UserProfile Domain
toEntity_shouldConvertDomainToEntity UserProfile Domain -> UserProfileEntity

UserProfilePersistenceAdapterTest

테스트 메서드 시나리오
saveUserProfile_shouldSaveProfile_whenValid 프로필 저장 테스트
existsUserProfileByUserId_shouldReturnTrue_whenProfileExists 프로필 존재 여부 확인 테스트
existsUserProfileByUserId_shouldReturnFalse_whenProfileDoesNotExist 2. 프로필이 존재하지 않으면 false를 반환한다
existsByNickname_shouldReturnTrue_whenNicknameExists 닉네임 중복 확인 테스트
existsByNickname_shouldReturnFalse_whenNicknameDoesNotExist 2. 닉네임이 존재하지 않으면 false를 반환한다
updateMyProfile_shouldUpdateProfile_whenProfileExists 프로필 업데이트 테스트
adapter-redis · 테스트 클래스 5개 · 테스트 메서드 27개

LoginAttemptRedisAdapterTest

테스트 메서드 시나리오
getLoginAttemptCount Redis에 저장된 로그인 시도 횟수를 조회하면 저장된 정수를 반환한다
getLoginAttemptCount_shouldReturnNull_whenKeyNotExists 키가 없으면 로그인 시도 횟수 조회가 null을 반환한다
increaseLoginAttempt_shouldReturnIncreasedValue_whenKeyExists 기존 카운트를 증가시키면 값이 1 증가한다
getLoginAttemptCount_shouldReturnNull_whenTtlExpired TTL이 지난 이후에는 로그인 시도 횟수 조회가 null을 반환한다

PostViewCountRedisAdapterTest

테스트 메서드 시나리오
recordPostView_shouldStoreRecordView_whenRecordNotExists 조회 기록이 없을 때 recordPostView가 Redis 키를 생성한다
recordPostView_shouldStoreRecordView_whenRecordExists 이미 저장된 조회 기록이 있어도 recordPostView가 정상 동작한다
existPostView_shouldReturnTrue_whenRecordNotExists 조회 기록이 없으면 existsPostView가 false를 반환한다
existPostView_shouldReturnTrue_whenRecordExists 조회 기록이 있으면 existsPostView가 true를 반환한다
existsPostView_shouldReturnFalse_whenTtlExpired TTL 만료 후에는 existsPostView가 false로 평가된다

EmailVerificationRedisAdapterTest

테스트 메서드 시나리오
getUserId_shouldReturnUserId_whenCodeExists 인증 코드를 저장하면 해당 코드로 사용자 ID를 조회할 수 있다
getUserId_shouldThrowException_whenCodeNotExists 존재하지 않는 인증 코드를 조회하면 EmailVerificationException이 발생한다
getUserId_shouldThrowException_whenTtlExpired TTL 만료 후 코드를 조회하면 EmailVerificationException이 발생한다
getUserId_shouldThrowException_whenCodeDeleted 삭제된 인증 코드를 조회하면 EmailVerificationException이 발생한다

TokenRepositoryTest

테스트 메서드 시나리오
upsertRefreshToken_shouldStoreNewToken_whenOldTokenExists 기존 토큰이 있을 때 upsertRefreshToken이 값을 갱신한다
upsertToken_shouldStoreNewToken_whenOldTokenNotExists 기존 토큰이 없을 때도 upsertRefreshToken이 새 토큰을 저장한다
existsRefreshToken_shouldReturnTrue_whenUserIdExists 저장된 사용자 ID로 refresh 토큰 존재 여부를 조회하면 true 를 반환한다
existsRefreshToken_shouldReturnFalse_whenUserIdNotExists 없는 사용자 ID로 조회하면 false 를 반환한다
existsBlackListToken_shouldReturnTrue_whenBlackListTokenExists 블랙리스트 토큰을 저장하면 존재 여부 조회가 true 를 반환한다
existsBlackListToken_shouldReturnFalse_whenBlackListTokenNotExists 저장되지 않은 토큰을 조회하면 false 를 반환한다
deleteRefreshToken_shouldReturnFalse_whenTokenIsDeleted refresh 토큰을 삭제한 뒤에는 Redis 키가 사라진다
saveBlackListToken_shouldTrue 블랙리스트 토큰 저장 시 Redis에 정상적으로 적재된다
existsRefreshToken_shouldReturnFalse_whenTtlExpired TTL이 만료된 refresh 토큰은 존재 여부 조회 시 false 로 반환된다
existsBlackListToken_shouldReturnFalse_whenTtlExpired TTL 이후 블랙리스트 토큰을 조회하면 false 로 반환된다

TokenRepositoryUnitTest

테스트 메서드 시나리오
existsRefreshTokenByUserId_shouldReturnTrue_ifUserIdExists Redis 키가 존재하면 true 를 반환하는지 검증
existsRefreshToken_shouldReturnFalse_ifUserNotExists Redis 키가 없으면 false 를 반환하는지 검증
upsertToken_shouldStoreRefreshToken_whenOldTokenExists 기존 토큰이 있을 때 upsertRefreshToken이 갱신 명령을 호출한다
upsertToken_shouldStoreRefreshToken_whenOldTokenNotExits 기존 토큰이 없을 때도 upsertRefreshToken이 저장 명령을 호출한다
adapter-storage · 테스트 클래스 1개 · 테스트 메서드 6개

LocalImageUploadAdapterTest

테스트 메서드 시나리오
uploadPostImageList_shouldUploadSuccessfully_whenImagesAreValid uploadPostImageList 테스트
uploadPostImageList_shouldReturnEmptyList_whenImageListIsEmpty uploadPostImageList - 빈 리스트를 업로드하면 빈 리스트가 반환되어야 한다
uploadPostImageList_shouldHaveUniqueFileNames_whenMultipleImagesUploaded uploadPostImageList - 여러 이미지가 고유한 파일명을 가져야 한다
uploadProfileImage_shouldUploadSuccessfully_whenImageIsValid uploadProfileImage 테스트
uploadProfileImage_shouldUploadSuccessfully_whenImageIsPng uploadProfileImage - PNG 확장자 이미지가 정상적으로 업로드되어야 한다
uploadImage_shouldHandleVariousExtensions_whenDifferentFormatsProvided 파일 확장자 처리 테스트
app-api · 테스트 클래스 46개 · 테스트 메서드 230개

CancelFollowRequestApiTest

테스트 메서드 시나리오
cancelFollowRequest_shouldSuccess_01 팔로우 요청 취소 API 테스트
cancelFollowRequest_shouldFaile_01 실패
cancelFollowRequest_shouldFaile_02 2, 존재하지 않는 팔로우 관계에 대해서 요청 취로를 할 경우 실패 검증
cancelFollowRequest_shouldFail_03 3. 이미 취소 처리된 팔로우 요청에 대해서 취소 요청을 할 경우 실패 검증

ChangePasswordApiTest

테스트 메서드 시나리오
changePasswordApiTest_shouldSuccess 사용자 비밀번호 변경 관련 API 테스트
changePasswordApiTest_shouldReturn400BadRequest_whenChangePasswordWithout2FA 실패

CreateMyProfileApiTest

테스트 메서드 시나리오
setUserProfile_shouldCreateOrUpdateProfile_whenAuthenticatedUserRequests 사용자 프로필 생성 테스트
setUserProfile_shouldReturn409Conflict_whenUserProfileExists 실패
setUserProfile_shouldReturn409Conflict_whenNicknameAlreadyExists 2. 중복된 닉네임으로 수정 요청을 보냈을 경우 409 Conflict
login_shouldReturn403_whenUserProfileNotSet 사용자 프로필을 설정하지 않은 상태에서 인증을 필요로한 경로에 접속 할 경우 403 Forbidden

CreatePostApiTest

테스트 메서드 시나리오
createPost_shouldCreatedContent_whenCreatePostWithValidInput 게시글 생성 테스트
createPost_shouldReturnBadRequest_whenContentIsBlank 실패
createPost_shouldReturnBadRequest_whenContentExceedsMaxLength 2. 게시글 내용이 최대 길이를 초과할 경우 400 BadRequest

CreatePostCommentApiTest

테스트 메서드 시나리오
createPostComment_shouldSucceed_whenPostIsActive 게시글 댓글 생성 테스트
createPostComment_shouldReturnBadRequest_whenPostIsDeleted 실패
createPostComment_shouldReturnBadRequest_whenPostIsBlocked 2. BLOCKED 상태의 게시글에 댓글 작성 요청을 하는 경우 400 Bad Request
createPostComment_shouldReturnBadRequest_whenPostIsArchived 3. ARCHIVE 상태의 게시글에 댓글 작성 요청을 하는 경우 400 Bad Request
createPostComment_shouldReturnBadRequest_whenContentIsEmpty 4. 비어있는 content로 요청을 보낼 경우 400 Bad Request
createPostComment_shouldReturnBadRequest_whenContentExceedsMaxLength 5. 댓글이 최대 길이를 초과할 경우 400 Bad Request

CreatePostCommentLikeApiTest

테스트 메서드 시나리오
likePostComment_shouldReturnCreated_whenUserLikesActiveComment 게시글 댓글 좋아요 테스트
likePostComment_shouldAccumulateLikeCount_whenMultipleUserLike 2. 여러 사용자가 댓글에 좋아요를 눌렀을 경우 응답 검증
likePostComment_shouldBeIdempotent_whenUserLikesSameCommentMultipleTimes 3. 동일한 사용자가 여러번 요청을 보내도 멱등하는지 검증
likePostComment_shouldReturnBadRequest_whenCommentIsDeleted 실패
likePostComment_shouldReturnBadRequest_whenCommentIsBlocked 2. BLOCKED 상태의 댓글에 좋아요 요청 시 400 BadRequest

CreatePostWithImageTest

테스트 메서드 시나리오
createPostWithImages_shouldSucceed_whenUploadOneImage 성공

DeactivateMyAccountApiTest

테스트 메서드 시나리오
deactivateMyAccount_shouldSuccess_whenUserIdExists 내 계정 비활성화 테스트
deactivateMyAccount_shouldReturn403Forbidden_whenUserRequestAuthorizedEndPointAfterWithdraw 실패
deactivateMyAccount_shouldReturn400BadRequest_whenAccessAuthorizedPathAfterUserDeactivate 2. 계정 비활성화 후 인증을 필요로한 경로로 접근이 불가능한지 검증
deactivateMyAccount_shouldReturn400BadRequest_whenDeactivateWithout2FA 3. 이중인증 없이 비활성화를 요청 할 경우 불가능한지 검증
deactivateMyAccount_shouldReturn_whenReissueAccessTokenAfterUserDeactivate 4. 계정 비활성화 후 토큰 재발급 불가능한지 검증

DeletePostApiTest

테스트 메서드 시나리오
deletePostWithImage_shouldSucceed_whenHasImage 성공
deletePostWithImage_shouldSucceed_whenHasNotImage 2. 이미지가 없는 게시글 삭제 요청 시 DELETED 상태 검증
deletePostWithImage_shouldSucceed_whenHasAllActivities 3. 모든 활동이 있는 게시글을에 대한 삭제 요청 시 데이터 검증
deletePostWithImage_shouldReturnNotFound_whenPostIdNotFound 1. 존재하지 않는 postId로 삭제 요청 시 404 Not Found
deletePostWithImage_shouldReturnBadRequest_whenPostAlreadyDeleted 2. 이미 삭제된 게시글에 대해 삭제 요청 시 400 Bad Request
deletePostWithImage_shouldReturnBadRequest_whenPostBlocked 3. 차단된 게시글을 삭제 요청 시 400 Bad Request
deletePostWithImage_shouldReturnForBidden_whenPostWriterNotEqualsRequester 4. 게시글 작성자와 삭제 요청자가 일치 하지 않는 경우 403 Forbidden

DeletePostCommentLikeApiTest

테스트 메서드 시나리오
cancelPostCommentLike_shouldCancelLikeAndDecreaseLikeCountWhenAlreadyLiked 게시글 댓글 좋아요 취소 테스트
cancelPostCommentLike_shouldBeIdempotentWhenCancelLikeMultipleTimes 2. 사용자가 여러번 좋아요 취소 요청을 보내도 멱등한지 검증
cancelPostCommentLike_shouldNotFailWhenUserDidNotLikeBefore 3. 사용자가 좋아요를 누르지 않은 상태에서 취소 요청 시 멱등한지 검증

DeletePostLikeApiTest

테스트 메서드 시나리오
cancelPostLike_shouldReturnCreated_whenUserLikedPost 게시글 좋아요 취소 테스트
cancelPostLike_shouldBeIdempotent_whenUserMultipleRequest 2. 사용자가 좋아요를 누른 게시글에 좋아요 취소 요청을 여러번 보내도 멱등하는지 검증
cancelPostLike_shouldIdempotent_whenUserLikedPostMultipleRequest 3. 사용자가 좋아요를 누르지 않은 게시글에 좋아요 취소 요청을 보내면 멱등하는지 검증
cancelPostLike_shouldReturnBadRequest_whenPostDeleted 실패
cancelPostLike_shouldReturnBadRequest_whenPostBlocked 2. BLOCKED 상태의 게시글에 좋아요 취소 요청을 보내면 BadRequest
cancelPostLike_shouldReturnBadRequest_whenPostArchive 3. ARCHIVE 상태의 게시글에 좋아요 취소 요청을 보내면 BadRequest

FollowUserApiTest

테스트 메서드 시나리오
followUser_shouldSuccess_01 사용자 팔로우 요청 관련 API 테스트
followUser_shouldSuccess_02 2. 비공개 계정을 팔로우 요청하는 경우 검증
followUser_shouldFail_01 실패
followUser_shouldFail_02 2. 탈퇴 처리된 사용자를 팔로우 요청하는 경우 실패 검증
followUser_shouldFail_03 3. 비활성화 처리 된 사용자를 팔로우 요청하는 경우 실패 검증
followUser_shouldFail_04 4. 자신에게 팔로우 요청을 하는 경우 실패 검증

GetFollowRequestsApiTest

테스트 메서드 시나리오
getFollowRequests_shouldSuccess_01 팔로우 요청 목록 조회 API 테스트
getFollowRequests_shouldSuccess_02 2. 팔로우 요청 목록 전체 조회 검증
getFollowRequests_shouldSuccess_03 3. 비공개 계정에 팔로우 요청 시 팔로우 요청 목록에 추가 되는지 검증
getFollowRequests_shouldSuccess_04 4. 공개 계정에 팔로우 요청 시 팔로우 요청 목록에 추가 되지 않는지 검증
getFollowRequests_shouldSuccess_05 5. 팔로우 요청 취소 시 팔로우 요청 목록에 불포함되어 있는지 검증

GetFollowStatsApiTest

테스트 메서드 시나리오
getUserFollowStats_shouldSuccess_01 사용자 팔로워, 팔로잉 수 조회 API 테스트
getUserFollowStats_shouldSuccess_02 2. 정상적인 팔로워, 팔로잉 수 조회 요청 응답 검증
getUserFollowStats_shouldSuccess_03 3. 팔로워 및 팔로잉 사용자 탈퇴 후 조회 시 각각 수가 감소되는지 검증
getUserFollowStats_shouldSuccess_04 4. 팔로워 및 팔로잉 사용자 비활성화 후 조회 시 각각 수가 감소되는지 검증
getUserFollowStats_shouldSuccess_05 5. PENDING 상태의 팔로우가 포함 되지 않는지 검증
getUserFollowStats_shouldFail_01 실패
getUserFollowStats_shouldFail_02 2. 탈퇴 처리된 사용자에 대한 요청 응답 검증
getUserFollowStats_shouldFail_03 3. 비활성화 처리된 사용자에 대한 요청 응답 검증

GetFollowersApiTest

테스트 메서드 시나리오
getFollowers_shouldSuccess_01 팔로워 조회 요청 관련 API Test
getFollowers_shouldSuccess_02 2. 팔로우 요청 후 해당 사용자가 팔로워 목록에 포함되는지 검증
getFollowers_shouldSuccess_03 3. 팔로우 요청 수락 대기중인 사용자가 팔로워 목록에 포함되는지 검증
getFollowers_shouldSuccess_04 4. 언팔로우 후 상대방의 팔로워 목록에서 제거되는지 검증
getFollowers_shouldSuccess_05 5. 팔로워 삭제 후 상대방이 팔로워 목록에서 제거되는지 검증
getFollowers_shouldSuccess_06 6.팔로워가 있는 사용자의 팔로워 목록 전제 조회 검증
getFollowers_shouldSuccess_07 7. 팔로워 목록에서 비활성화 된 사용자가 포함되는지 검증
getFollowers_shouldSuccess_08 8. 팔로워 목록에서 탈퇴처리 된 사용자가 포함되는지 검증
getFollowers_shouldSuccess_09 9. 다른 사용자의 팔로워 목록 전체 조회 검증
getFollowers_shouldSuccess_10 10. 비공개 계정이면서 팔로우 상태인 사용자의 팔로워 목록 전제 조회 검증
getFollowers_shouldFail_01 실패

GetFollowingsApiTest

테스트 메서드 시나리오
getFollowings_shouldSuccess_01 팔로잉 조회 요청 관련 API Test
getFollowings_shouldSuccess_02 2. 팔로우 요청 후 해당 사용자가 팔로잉 목록에 포함되는지 검증
getFollowings_shouldSuccess_03 3. 팔로우 요청 수락 대기중인 사용자가 팔로잉 목록에 포함되는지 않는지 검증
getFollowings_shouldSuccess_04 4. 언팔로우 후 팔로잉 목록에서 제거되는지 검증
getFollowings_shouldSuccess_05 5. 팔로워 삭제 후 상대방의 팔로잉 목록에서 제거되는지 검증
getFollowings_shouldSuccess_06 6.팔로잉 하는 사용자가 있는 사용자의 팔로워 목록 전제 조회 검증
getFollowings_shouldSuccess_07 7. 팔로잉 목록에서 비활성화 된 사용자가 포함되는지 검증
getFollowings_shouldSuccess_08 8. 팔로잉 목록에서 탈퇴처리 된 사용자가 포함되는지 검증
getFollowings_shouldSuccess_09 9. 공개 계정인 다른 사용자의 팔로워 목록 전체 조회 검증
getFollowings_shouldSuccess_10 10. 비공개 계정이면서 팔로우 상태인 사용자의 팔로잉 목록 전제 조회 검증
getFollowings_shouldFail_01 실패

GetMyProfileApiTest

테스트 메서드 시나리오
getMyProfileDetails_shouldSuccess 내 프로필 조회 관련 API 테스트

GetPostApiTest

테스트 메서드 시나리오
getPost_shouldReturnOk_whenGetExistingPost 게시글 조회 테스트
getPost_shouldReturnSameContentAndId_whenGetPostAfterCreation 2. 게시글 작성 후 조회 시 작성한 내용과 postId가 동일한지 검증
getPost_shouldReturnSameContentAndId_whenGetPostAfterUpdate 3. 게시글 작성 후 수정 시, 조회하면 수정된 내용이 조회되는지 검증
getPost_shouldReturnNotFound_whenGetNotExistingPost 실패
getPostList_shouldReturnOk_whenGetExistingPost 게시글 목록 조회 테스트
getPostList_shouldIterateAllPages_usingCursorPagination 2. 커서 기반 페이징으로 전체 게시글 마지막 페이지까지 순회하며 조회
getPostEngagement_shouldNotFound_whenPostNotExists 실패

GetPostCommentApiTest

테스트 메서드 시나리오
getPostCommentList_shouldReturnNextCursor_whenFirstPageRequested 게시글 댓글 목록 커서 기반 조회
getPostCommentList_shouldReturnAllComments 2. 게시글 댓글 목록 전체 조회 검증
getPostCommentList_shouldReflectLikedField_whenLikeRequest 3. 게시글 댓글 좋아요 요청 후 댓글 목록 조회 시 해당 댓글의 liked 필드가 true로 변하는지 검증
getPostCommentList_shouldReturnBadRequest_whenPostIsDeleted 실패
getPostCommentList_shouldReturnBadRequest_whenPostIsArchive 2. ARCHIVE 상태의 게시글 댓글 목록 조회 시 400 Bad Request
getPostCommentList_shouldReturnBadRequest_whenPostIsBlocked 3. BLOCKED 상태의 게시글 댓글 목록 조회 시 400 Bad Request
getPostCommentList_shouldReturnBadRequest_whenPostNotExists 4. 존재하지 않는 게시글의 댓글 목록 요청 시 400 Not Found

GetPostCommentLikeApiTest

테스트 메서드 시나리오
getPostCommentLikers_shouldReturnFirstPage 게시글 댓글 좋아요 목록 조회 테스트
getPostLikers_shouldReturnEmptyList_whenPostCommentHasNotLikes 2. 좋아요가 없는 댓글에 요청 시 빈 리스트가 반환되는지 검증
getPostLikers_shouldIteratorAllPages_whenUsingCursorPagination 3. 전체 좋아요 목록 조회 시 마지막 페이지까지 순회 조회 되는지 검증
getPostLikers_shouldReturnNotFound_whenPostCommentLNotExists 실패
getPostLikers_shouldReturnBadRequest_whenPostCommentIsDeleted 2. DELETED 상태의 댓글에 대한 요청 시 400 BadRequest

GetPostLikeApiTest

테스트 메서드 시나리오
getPostLikers_shouldReturnLikers_whenPostHasLikers 게시글 좋아요 목록 조회 테스트
getPostLikers_shouldReturnEmptyList_whenPostHasNotLikes 2. 좋아요가 없는 게시글에 요청 시 빈 리스트가 반환되는지 검증
getPostLikers_shouldReturnNotFound_whenPostNotFound 실패
getPostEngagement_shouldReturnCorrectLikeCount_whenPostHasLikes 게시글 좋아요 요약 조회 테스트

GetUserProfileApiTest

테스트 메서드 시나리오
getUserProfile_shouldSuccess_01 성공
getUserProfile_shouldSuccess_02 2. 공개 계정을 팔로우한 상태에서 APPROVED 상태로 프로필 조회 가능
getUserProfile_shouldSuccess_03 3. 비공개 계정을 팔로우 승인받은 상태에서 APPROVED 상태로 프로필 조회 가능
getUserProfile_shouldSuccess_04 4. 본인 프로필 조회 시 SELF 상태로 조회 가능
getUserProfile_shouldSuccess_05 5. 비공개 계정을 팔로우하지 않은 상태에서 NONE 상태로 기본 프로필 조회 가능
getUserProfile_shouldSuccess_06 6. 비공개 계정에 팔로우 요청 대기중인 상태에서 PENDING 상태로 기본 프로필 조회 가능
getUserProfile_shouldFail_01 실패
getUserProfile_shouldFail_03 2. 사용자는 존재하지만 profile이 없는 경우 404 Not Found
getUserProfile_shouldFail_04 3. 탈퇴 처리된 사용자의 프로필을 조회할 경우 403 Forbidden
getUserProfile_shouldFail_05 4. 비활성화 된 사용자를 조회하는 경우 403 Forbidden

HandleFollowRequestApiTest

테스트 메서드 시나리오
approveFollowRequest_shouldSuccess_01 팔로우 요청 수락 및 거절 API 테스트
approveFollowRequest_shouldFail_01 실패
approveFollowRequest_shouldFail_02 2. 내가 받은 팔로우 요청이 아닌 경우 실패 검증
approveFollowRequest_shouldFail_03 3. 이미 수락한 팔로우 요청에 대한 수락 요청 시 실패 검증
rejectFollowRequest_shouldSuccess_01 팔로우 요청 거절 테스트
rejectFollowRequest_shouldFail_01 실패
rejectFollowRequest_shouldFail_02 2. 내가 받은 팔로우 요청이 아닌 경우 실패 검증
rejectFollowRequest_shouldFail_03 3. 이미 거절한 팔로우 요청에 대한 요청 시 실패 검증

IncreaseViewCountApiTest

테스트 메서드 시나리오
increaseViewCount_shouldIncrease_whenUserGetPost 게시글 조회 수 증가 테스트
increaseViewCount_shouldIdempotent_whenUserMultipleRequest 2. 사용자가 게시글을 여러번 조회 시 멱등한지 검증
increaseViewCount_shouldIncreaseViewCount_whenUserRequestAfterFewTimes 3. 사용자가 게시글을 조회 후 시간이 지난 후 다시 조회 시 조회 수가 증가하는지 검증
increaseViewCount_shouldIncreaseViewCount_whenMultipleUserRequest 4. 여러 사용자가 게시글 조회 시 조회 수가 증가하는지 검증

JwtApiTest

테스트 메서드 시나리오
userProfileCompleteTest_shouldSuccess_whenUserSetProfile Jwt 인증 관련 API 테스트
userProfileCompleteTest_shouldSuccess_whenUserSetProfile 실패

LikePostApiTest

테스트 메서드 시나리오
likePost_shouldReturnCreated_whenUserLikesActivePost 게시글 좋아요 테스트
likePost_shouldBeIdempotent_whenUserLikesSamePostMultipleTimes 2. 동일 사용자가 중복 좋아요 요청 시 멱등하게 처리되는지 검증
likePost_shouldAccumulateLikeCount_whenMultipleUserLike 2. 여러 사용자가 게시글에 좋아요를 누를 경우 likeCount 누적되는지 검증
likePost_shouldReturnBadRequest_whenPostDeleted 실패
likePost_shouldReturnBadRequest_whenPostBlocked 2. BLOCKED 상태의 게시글에 좋아요 요청 시 400 Bad Reqeust
likePost_shouldReturnBadRequest_whenPostArchive 3. ARCHIVE 상태의 게시글에 좋아요 요청 시 400 Bad Reqeust

LoginAttemptLimiterTest

테스트 메서드 시나리오
upsertLoginAttempt_shouldReturnTrue_whenLoginAttemptLessThanFive loginAttempt가 존재하지 않을 경우 - true 리턴
upsertLoginAttempt_shouldReturnTrue_whenLoginAttemptReachThanFive loginAttempt가 5이상일 경우 - false 리턴
upsertLoginAttempt_shouldReturnThree_whenLoginAttemptReachCallThree userId에 해당하는 값이 존재하지 않는 상황에서 3번 호출된 후 조회 시 3이 나와야 한다
upsertLoginAttempt_shouldReturnFive_andFalse_whenLoginAttemptReachCallSix 6번 호출된 후 조회 시 5가 나와야 하고 false가 return 되어야 한다
incrementLoginAttempt_shouldReturnOne_whenLoginAttemptNotExists loginAttempt가 존재하지 않는 경우, 실행시 1이 더해져야 함
incrementLoginAttempt_shouldReturnFive_whenLoginAttemptIsFive loginAttempt가 5인 경우, 더 이상 업데이트 되지 않고 5로 유지되어야 함
deleteLoginAttempt_shouldReturnNull login attempt를 삽입한 후 실행, 이후 조회시 null이 나와야한다

LoginScenarioTest

테스트 메서드 시나리오
accessProtectedResource_shouldSucceed_whenLoggedIn 로그인 시나리오 테스트
accessProtectedResource_sholudReturnUnAuthorized_whenAccessTokenNotExists 성공-2. 로그인 후 만료된 accessToken으로 접속'/' -> TLY3000 -> 재접속
accessProtectedResource_shouldSucceed_afterAccessTokenExpired_whenReissueAccessToken 성공-3. 로그인 후 만료된 accessToken으로 접속'/' -> TLY3000 -> 재발급 후 재 접속
verifyLoginTokens_shouldBeUnique_whenForEachLogin 성공-4. 여러 번 로그인 시 매번 새로운 accessToken, refreshToken 발급
checkLoginAttempt_shouldAllowLogin_whenTtlExpires 성공-5. 로그인 제한 후 시간이 지나면 초기화, 이후 로그인 시도
checkLoginAttempt_shouldFail_whenExceededMaxAttempts 실패-1. 잘못된 비밀번호로 5회 이상 로그인 시도 할 경우
checkLoginAttempt_shouldResetAndBlock_whenSuccessAndExceeded 실패-2. 정상 로그인시 시도 횟수가 초기화되고 이후 잘못된 비밀번호로 5회 초과시 로그인 제한

LoginTest

테스트 메서드 시나리오
login_shouldSucceed_whenUserExistsAndCorrectPassword 성공
login_shouldFail_whenUserNotExists 실패
login_shouldFail_whenPasswordNotCorrect 2. 비밀번호가 일치하지 않는 경우
login_shouldFail_whenEmailNotVerified 3. 이메일 인증이 되지 않은 경우

LogoutScenarioTest

테스트 메서드 시나리오
accessProtectedResource_shouldFail_afterLogout 로그아웃 시나리오 테스트

LogoutTest

테스트 메서드 시나리오
logout_shouldSucceed_whenLoginSucceed 성공
logout_shouldFailed_whenLoginSucceed_andTokenInvalid 실패
logout_shouldFailed_whenLoginSucceed_andTokenExpired 실패-2. 만료된 accessToken으로 요청
verifyPassword_shouldReturnVerificationToken_whenValidPassword 이중 인증 테스트
passwordVerificationToken_shouldFailed_whenInValidPassword 실패-1. 비밀번호가 일치하지 않는 경우

PasswordVerificationScenarioTest

테스트 메서드 시나리오
accessProtectedResource_shouldSucceed_afterPasswordVerification 사용자 이중 인증 시라니오 테스트
accessProtectedResource_shouldFail_afterXVerificationTokenExpired 실패-1. X-Verification-token 만료후 접속

PostSearchApiTest

테스트 메서드 시나리오
searchPost_shouldReturnSingleResult_whenSearchWithUniqueKeyword 성공
searchPost_shouldReturnMultipleResults_whenSearchWithCommonKeyword 2. keyword 검색 후 검색 결과 리스트 검증
searchPost_shouldReturnEmptyList_whenSearchWithNonExistentKeyword 3. 존재하지 않는 데이터에 대한 검색 결과 검증
searchPost_shouldIncludePublicUserPost_whenNotFollowing 4. 팔로우 상태가 아니면서 공개 계정의 사용자가 올린 게시글이 검색되는지 검증
searchPost_shouldIncludePrivateUserPost_whenFollowing 5. 팔로우 상태이면서 비공개 계정인 사용자가 올린 게시글이 검색되는지 검증
searchPost_shouldIncludeMyPost_whenSearchingOwnContent 6. 내가 올린 게시글이 검색되는지 검증
searchPost_shouldReturnSortedByRecent_whenSortTypeIsRecent 7. sortType = RECENT인 경우 응답 검증
searchPost_shouldReturnSortedByPopular_whenSortTypeIsPopular 8. sortType = POPULAR인 경우 응답 검증
searchPost_shouldIterateAllPages_usingCursorPagination 9. 커서 기반 페이징으로 전체 검색 결과를 마지막 페이지까지 순회하며 조회
searchPost_shouldReturnAllPosts_whenKeywordIsNull 실패
searchPost_shouldNotIncludePrivateUserPost_whenNotFollowing 2. 팔로우 상태가 아니면서 비공개 계정의 사용자가 올린 게시글이 검색되지 않는지 검증
searchPost_shouldReturnError_whenSortTypeIsInvalid 3. 유효하지 않은 sortType(RELEVANCE) 사용 시 적절한 에러 반환

RemoveFollowerApiTest

테스트 메서드 시나리오
removeFollower_shouldSuccess_01 팔로워 삭제 API 테스트
removeFollower_shouldFail_01 실패
removeFollower_shouldSuccess_01 2. PENDING 상태의 사용자를 팔로워 삭제 요청 시 실패 검증

SampleTest

테스트 메서드 시나리오
test -

UnfollowApiTest

테스트 메서드 시나리오
unfollowUser_shouldSuccess_01 사용자 언팔로우 API 테스트
unfollowUser_shouldFail_01 실패
unfollowUser_shouldSuccess_01 2. PENDING 상태의 사용자를 언팔로우 요청 시 실패 검증

UpdateMyProfileApiTest

테스트 메서드 시나리오
updateMyProfile_shouldDeleteExistingProfileImage_whenProfileImageIdIsNull 성공
updateMyProfile_shouldUpdateProfileImage_whenProfileImageIdIsDifferent 2. 기존 프로필 이미지가 존재하고 새로운 프로필 이미지를 설정하는 경우 검증
updateMyProfile_shouldKeepExistingProfileImage_whenImageIdIsSame 3. 기존 프로필 이미지가 존재하고 기존 프로필 이미지를 유지하는 경우 검증
updateMyProfile_shouldSetNewProfileImage_whenNoExistingProfileImageAndProfileImageIdIsGiven 4. 기존 프로필 이미지가 존재하지 않고 새로운 프로필 이미지를 설정하는 경우 검증
updateMyProfile_shouldDoNotingToProfileImage_whenNoExistingImageAndImageIdIsNull 5. 기존 프로필 이미지가 존재하지 않고 새 프로필을 설정하지 않는 경우 검증
updateUserProfile_shouldReturn409Conflict_whenRequestNicknameAlreadyExists 실패
updateMyProfile_shouldFail_whenProfileImageIdIsInvalid 2. 존재하지 않는 profileImageId로 업데이트 요청 시 404 Not Found
updateMyProfile_shouldReturn404NotFound_whenProfileImageIdStatusIsDeleted 3. DELETED 상태의 profileImageId로 업데이트 요청 시 404 Not Found

UpdatePostApiTest

테스트 메서드 시나리오
updatePost_shouldUpdatePostSuccessfully_whenWriterRequestsUpdate 게시글 업데이트 테스트
updatePost_shouldReturnForbidden_whenNonWriterTriesToUpdatePost 실패
updatePost_shouldReturnNotFound_whenRequestNotExistsPostId 2. 작성자가 존재하지 않는 postId로 수정 요청 할 경우
updatePost_shouldReturnBadRequest_whenContentIsBlank 3. 작성자가 비어있는 content로 요청 할 경우
updatePost_shouldReturnBadRequest_whenContentExceedsMaxLength 4. 게시글 수정 내용이 최대 길이를 초과할 경우 400 BadRequest

UpdatePostCommentApiTest

테스트 메서드 시나리오
deletePostComment_shouldReturn204_whenCommentIsActive 게시글 댓글 삭제 테스트
deletePostComment_shouldReturnBadRequest_whenPostIsBlocked 실패
deletePostComment_shouldReturnForbidden_whenCommentWriterNotEqualsUser 2. 댓글 작성자가 아닌 사용자가 삭제 요청 시 403 Forbidden
deletePostComment_shouldReturn400_whenCommentIsDeleted 3. 이미 삭제된 댓글 삭제 요청 시 400 Bad Request

UpdatePostStatusApiTest

테스트 메서드 시나리오
deletePost_shouldExcludePostFromPostList_afterSuccessfulDeletion 게시글 삭제 테스트
deletePost_shouldReturnBadRequest_whenAlreadyDeleted 실패
deletePost_shouldReturnForbidden_whenNonOwnerRequest 2. 게시글 작성자가 아닌 사용자가 삭제 요청 시 403 Forbidden

UploadPostImageValidateApiTest

테스트 메서드 시나리오
uploadImage_shouldSucceed_whenValidImageUpload 성공
uploadImage_shouldSucceed_whenUploadMaxCount 2. 정상적인 이미지를 최대 허용 수 만큼 업로드 시 응답 검증
uploadImage_shouldReturnBadRequest_whenImageIsEmpty 실패
uploadImage_shouldReturnBadRequest_whenImageIsNull 2. 이미지가 null인 상태에서 요청시 400 Bad Request
uploadImage_shouldReturnBadRequest_whenUploadOverMaxCount 3. 최대 허용 수를 초과하는 이미지 요청 시 400 Bad Request
uploadImage_shouldReturnBadRequest_whenUploadOverMaxSize 4. 최대 허용 용량 이상이 이미지 요청 시 400 Bad Request
uploadImage_shouldReturnBadRequest_whenUploadFileExtensionNotSupported 5. 지원하지 않는 확장자의 파일을 요청 시 400 Bad Request

UploadProfileImageApiTest

테스트 메서드 시나리오
uploadMyProfileImage_shouldSuccess 성공

User2FATest

테스트 메서드 시나리오
verifyPassword_shouldReturnVerificationToken_whenValidPassword 성공
passwordVerificationToken_shouldFailed_whenInValidPassword 실패

UserSearchApiTest

테스트 메서드 시나리오
searchUser_shouldReturnSingleResult_whenSearchWithUniqueKeyword 성공
searchUser_shouldReturnMultipleResults_whenSearchWithCommonKeyword 2. keyword 검색 후 검색 결과 리스트 검증
searchUser_shouldReturnEmptyList_whenSearchWithNonExistentKeyword 3. 존재하지 않는 닉네임에 대한 검색 결과 검증
searchUser_shouldReturnApprovedStatus_whenSearchingFollowingUser 4. 팔로잉하는 사용자 검색 시 응답의 followStatus가 APPROVED인지 검증
searchUser_shouldReturnNoneStatus_whenSearchingNotFollowingUser 5. 팔로잉하지 않는 사용자 검색 시 응답의 followStatus가 NONE인지 검증
searchUser_shouldReturnSelfStatus_whenSearchingMyProfile 6. 내 프로필 검색 시 응답의 followStatus가 SELF인지 검증
searchUser_shouldIterateAllPages_usingCursorPagination 7. 커서 기반 페이징으로 전체 검색 결과를 마지막 페이지까지 순회하며 조회
searchUser_shouldReturnAllUsers_whenKeywordIsNull 실패

ValidateMyProfileApiTest

테스트 메서드 시나리오
checkNickname_shouldSuccess_whenNicknameIsUnique 성공
checkNickname_should409Conflict_whenNicknameAlreadyExists 실패

WithdrawMyAccountApiTest

테스트 메서드 시나리오
withdrawUser_shouldSuccess_whenUserIdExists 내 계정 탈퇴 테스트
withdrawUser_shouldReturn400BadRequest_whenUserWithdraw 실패
withdrawUser_shouldReturn400BadRequest_whenXVerifyTokenMissing 2. 이중인증 없이 회원 탈퇴 요청 시 400 BadRequest
withdrawUser_shouldReturn400BadRequest_whenReissueAccessTokenAfterWithdraw 3. 회원 탈퇴 후 토큰 재발급이 불가능한지 검증
app-batch · 테스트 클래스 6개 · 테스트 메서드 20개

ImageHardDeleteDeletedJobConfigTest

테스트 메서드 시나리오
shouldExecuteImageHardDeleteDeletedJobSuccessfully imageHardDeleteDeletedJob
shouldCompleteSuccessfullyWhenNoTargetData 2. 대상 데이터가 없을 때 Flow Job이 성공적으로 완료된다
shouldExecuteAllStepsInFlow 3. Flow Job의 모든 Step이 순차적으로 실행되고 완료된다

ImageHardDeleteTemporaryJobConfigTest

테스트 메서드 시나리오
shouldExecuteImageHardDeleteTemporaryJobSuccessfully imageHardDeleteTemporaryJob
shouldCompleteSuccessfullyWhenNoTargetData 2. 대상 데이터가 없을 때 Flow Job이 성공적으로 완료된다
shouldExecuteAllStepsInFlow 3. Flow Job의 모든 Step이 순차적으로 실행되고 완료된다

PostHardDeleteDeletedStatusJobConfigTest

테스트 메서드 시나리오
shouldDeletePostsWithDeletedStatus 1. DELETED 상태의 Post가 삭제 기준 시각 이전에 수정 되었으면 정상적으로 삭제 되는지 검증
shouldNotDeletePostsWithDeletedStatus_whenNotExpired 2. DELETED 상태의 Post가 삭제 기준 시각에 적용되지 않으면 삭제 되지 않는지 검증
shouldCompleteSuccessfullyWhenNoDeletedPosts 3. DELETED 상태의 Post가 없으면 배치 작업이 성공하며 아무것도 삭제하지 않는다

PostImageHardDeleteDeletedStatusJobConfigTest

테스트 메서드 시나리오
shouldDeletePostImagesWithDeletedStatus 1. DELETED 상태의 PostImage가 삭제 기준 시각 이전에 수정 되었으면 정상적으로 삭제 되는지 검증
shouldDeletePostImagesWithDeletedStatus_02 2. DELETED 상태의 postImage가 삭제 기준 시각에 적용되지 않으면 삭제 되지 않는지 검증
shouldCompleteSuccessfullyWhenNoDeletedImages 3. DELETED 상태의 PostImage가 없으면 배치 작업이 성공하며 아무것도 삭제하지 않는다
shouldExecuteStepSuccessfully 4. Step만 실행해도 정상 동작한다

PostImageHardDeleteTemporaryStatusJobConfigTest

테스트 메서드 시나리오
shouldDeletePostImagesWithDeletedStatus 1. TEMPORARY 상태의 PostImage가 삭제 기준 시각 이전에 수정 되었으면 정상적으로 삭제 되는지 검증
shouldDeletePostImagesWithDeletedStatus_02 2. TEMPORARY 상태의 postImage가 삭제 기준 시각에 적용되지 않으면 삭제 되지 않는지 검증
shouldCompleteSuccessfullyWhenNoDeletedImages 3. TEMPORARY 상태의 PostImage가 없으면 배치 작업이 성공하며 아무것도 삭제하지 않는다
shouldExecuteStepSuccessfully 4. Step만 실행해도 정상 동작한다

UserHardDeleteDeletedStatusJobConfigTest

테스트 메서드 시나리오
shouldDeleteUsersWithDeletedStatus 1. DELETED 상태의 User가 삭제 기준 시각 이전에 수정 되었으면 정상적으로 삭제 되는지 검증
shouldNotDeleteUsersWithDeletedStatus_whenNotExpired 2. DELETED 상태의 User가 삭제 기준 시각에 적용되지 않으면 삭제 되지 않는지 검증
shouldCompleteSuccessfullyWhenNoDeletedUsers 3. DELETED 상태의 User가 없으면 배치 작업이 성공하며 아무것도 삭제하지 않는다
core-domain · 테스트 클래스 5개 · 테스트 메서드 33개

FollowTest

테스트 메서드 시나리오
createFollow_shouldCreateFollowWithPendingStatus createFollow - 팔로우가 PENDING 상태로 생성되어야 한다
markAsApproved_shouldChangeStatusToApproved markAsApproved - PENDING 상태에서 APPROVED로 변경되어야 한다
markAsApproved_shouldNotChange_whenNotPending markAsApproved - SELF 상태에서 변경되지 않아야 한다
markAsSelf_shouldChangeStatusToSelf markAsSelf - SELF 상태로 변경되어야 한다

PostCommentTest

테스트 메서드 시나리오
newComment_shouldCreateCommentSuccessfully newComment - 댓글이 정상적으로 생성되어야 한다
markAsDeleted_shouldChangeStatusToDeleted markAsDeleted - DELETED 상태로 변경되어야 한다
validateDeletableBy_shouldThrowException_whenUserNotWriter validateDeletableBy - 작성자가 아닌 경우 예외 발생
validateDeletableBy_shouldThrowException_whenAlreadyDeleted validateDeletableBy - DELETED 상태인 경우 예외 발생
validateLikeable_shouldThrowException_whenNotActive validateLikeable - DELETED 상태에서 예외 발생
like_shouldCreateLikeSuccessfully like - 댓글 좋아요가 정상적으로 생성되어야 한다

PostTest

테스트 메서드 시나리오
newPost_shouldCreatePostSuccessfully newPost - 게시글이 정상적으로 생성되어야 한다
increaseViewCount_shouldIncreaseViewCountByOne increaseViewCount - increaseViewCount 호출 시 조회수가 1 증가해야 한다
increaseViewCount_shouldIncreaseViewCountByMaxTimes increaseViewCount - increaseViewCount 반복 호출 시 조회수가 누적 증가해야 한다
validateLikable_shouldThrowException_whenNotActive validateLikable - DELETED 상태에서 예외 발생
addLike_shouldCreateLikeSuccessfully addLike - 게시글 좋아요가 정상적으로 생성되어야 한다
markAsDeleted_shouldChangeStatusToDeleted markAsDeleted - DELETED 상태로 변경되어야 한다
markAsBlocked_shouldChangeStatusToBlocked markAsBlocked - BLOCKED 상태로 변경되어야 한다
markAsArchived_shouldChangeStatusToArchived markAsArchived - ARCHIVE 상태로 변경되어야 한다
addComment_shouldAddCommentSuccessfully addComment - 댓글이 정상적으로 추가되어야 한다
addComment_shouldAddMultipleComments addComment - 반복 호출 시 여러 댓글이 정상 추가 되어야 한다
updateContent_UpdatePostContet updateContent - 게시글 content 수정 시 변경된 내용이 반환되어야 한다

UserProfileTest

테스트 메서드 시나리오
setProfile_shouldCreateProfileSuccessfully setProfile - 프로필이 정상적으로 생성되어야 한다
updateProfile_shouldUpdateProfileSuccessfully updateProfile - 프로필이 정상적으로 업데이트되어야 한다

UserTest

테스트 메서드 시나리오
newUser_shouldCreateUserSuccessfully newUser - 사용자가 정상적으로 생성되어야 한다
verifyEmail_shouldMarkEmailAsVerified verifyEmail - 이메일 인증 시 상태가 true로 변경되어야 한다
markAsActive_shouldChangeStatusToActive markAsActive - ACTIVE 상태로 변경되어야 한다
markAsDeleted_shouldChangeStatusToDeleted markAsDeleted - DELETED 상태로 변경되어야 한다
markAsInactive_shouldThrowException_whenUserIsDeleted markAsInactive - DELETED 상태에서 예외가 발생해야 한다
markAsInactive_shouldChangeStatusToInactive markAsInactive - INACTIVE 상태로 변경되어야 한다
markAsBanned_shouldThrowException_whenUserIsDeleted markAsBanned - DELETED 상태에서 예외가 발생해야 한다
markAsBanned_shouldChangeStatusToBanned markAsBanned - BANNED 상태로 변경되어야 한다
setUserProfile_shouldCreateProfileSuccessfully setUserProfile - 프로필이 정상적으로 생성되어야 한다
markAsPrivate_shouldChangeToPrivate markAsPrivate - 비공개 상태로 변경되어야 한다
core-service · 테스트 클래스 27개 · 테스트 메서드 110개

EmailVerificationServiceTest

테스트 메서드 시나리오
verifyEmail_shouldUpdateAndPublishWelcomeMail 성공
verifyEmail_shouldThrow_whenUserNotFound 실패
verifyEmail_shouldThrow_whenAlreadyVerified 2. 이미 인증된 사용자라면 예외가 발생하는지 검증

FollowAccessValidatorTest

테스트 메서드 시나리오
validateProfileAccessibleWithException_shouldReturnSelf_whenSameUser 프로필 접근 가능 여부 검증 - 예외 포함
validateProfileAccessibleWithException_shouldThrow_whenPrivateAndNotApproved 2. 비공개 사용자이면서 팔로우가 승인되지 않은 경우 예외가 발생하는지 검증
validateProfileAccessibleWithException_shouldReturnApproved_whenPrivateAndApproved 3. 비공개 사용자이지만 팔로우가 승인된 경우 APPROVED가 반환되는지 검증
validateProfileAccessibleWithException_shouldReturnStatus_whenPublicUser 4. 공개 사용자 프로필은 팔로우 상태가 그대로 반환되는지 검증
validateProfileAccessible_shouldReturnSelf_whenSameUser 프로필 접근 가능 여부 검증 - 예외 미포함
validateProfileAccessible_shouldReturnNone_whenStatusNotFound 2. 팔로우 상태가 없는 경우 NONE이 반환되는지 검증

FollowCommandServiceTest

테스트 메서드 시나리오
followUser_shouldCreateApprovedFollow_whenTargetIsPublic 팔로우 요청 테스트
followUser_shouldCreatePendingFollow_whenTargetIsPrivate 팔로우 성공 - 비공개 계정인 경우 PENDING 상태로 생성되어야 한다
followUser_shouldThrowException_whenTargetIsSelf 팔로우 실패 - 자기 자신을 팔로우하는 경우 예외가 발생해야 한다
followUser_shouldThrowException_whenTargetNotFound 팔로우 실패 - 존재하지 않는 사용자인 경우 예외가 발생해야 한다
approveFollowRequest_shouldChangeStatusToApproved 팔로우 요청 수락 테스트
approveFollowRequest_shouldThrowException_whenRequestNotFound 팔로우 요청 수락 실패 - 존재하지 않는 요청인 경우 예외가 발생해야 한다
approveFollowRequest_shouldThrowException_whenNotMyRequest 팔로우 요청 수락 실패 - 다른 사용자의 요청인 경우 예외가 발생해야 한다
unfollowUser_shouldDeleteFollow 언팔로우 테스트
unfollowUser_shouldThrowException_whenFollowNotExists 언팔로우 실패 - 팔로우 관계가 존재하지 않는 경우 예외가 발생해야 한다
cancelFollowRequest_shouldDeleteRequest 팔로우 요청 취소 테스트

FollowQueryServiceTest

테스트 메서드 시나리오
getFollowRequestsByCursor_shouldReturnPagedResponse 팔로우 요청 목록 조회
getFollowers_shouldReturnPagedResponse 팔로워 목록 조회
getFollowings_shouldReturnPagedResponse 팔로잉 목록 조회
getUserFollowStats_shouldReturnStats 팔로우 통계 조회

ImageAspectRatioValidatorTest

테스트 메서드 시나리오
isValidAspectRatio_shouldReturnTrue_whenImageRatioIsValid 이미지 비율 검증 유틸 테스트
isValidAspectRatio_shouldReturnTrue_whenImageRatioIsValidAndMaxImageCount 2. 최대 허용 수 만큼의 일치하는 비율의 이미지 요청 시
isValidAspectRatio_shouldThrow_whenInvalidRatioImage 실패

ImageUploadValidatorTest

테스트 메서드 시나리오
validate_shouldPass_whenValidImageProvided 게시글 이미지 업로드 검증 테스트
validate_shouldThrow_whenImageNotExists 실패
validate_shouldThrow_whenImageCountIsMoreThenMaxCount 2. 허용된 업로드 수 초과 시 예외가 발생하는지 검증
validate_shouldThrow_whenSizeTooLarge 3. 이미지의 용량이 최대 허용 값 보다 큰 경우 예외가 발생하는지 검증
validate_shouldThrow_whenExtensionNotSupported 4. 지원하지 않는 파일 확장자로 요청 시 예외가 발생하는지 검증

MailEventListenerTest

테스트 메서드 시나리오
onSendMail_shouldDispatchVerificationMail 성공
onSendMail_shouldDispatchWelcomeMail 2. 환영 메일 이벤트를 수신하면 환영 메일이 전송되는지 검증

MailServiceTest

테스트 메서드 시나리오
sendWelcomeMail_shouldPublishWelcomeEvent 가입 환영 메일 전송
sendVerificationMail_shouldSaveCodeAndPublishEvent 이메일 인증 메일 전송

NotificationEventListenerTest

테스트 메서드 시나리오
onNotificationPublished_shouldCallService 성공
onNotificationPublished_shouldHandleExceptionGracefully 실패

NotificationServiceTest

테스트 메서드 시나리오
publish_shouldPublishNotification_whenActorExists 성공
publish_shouldThrow_whenActorNotFound 실패

PostCascadeCleanupListenerTest

테스트 메서드 시나리오
onPostDeleted_shouldInvokeCleanup 성공
onPostDeleted_shouldHandleExceptionGracefully 실패

PostCleanupCommandServiceTest

테스트 메서드 시나리오
cleanupAssociation_shouldCleanupAllResources 성공

PostCommandServiceTest

테스트 메서드 시나리오
increaseViewCount_shouldSuccess_whenUserRecordNotExists 게시글 조회수 증가 테스트
increaseViewCount_shouldSuccess_whenUserRecordExists 2. 사용자의 조회 기록이 있을 경우 요청 시 실행되지 않는지 검증

PostCommentCommandServiceTest

테스트 메서드 시나리오
createPostComment_shouldCreateComment_whenPostIsActive 댓글 생성 테스트
createPostComment_shouldThrowException_whenPostIsDeleted 댓글 생성 실패 - 삭제된 게시글인 경우 예외가 발생해야 한다
createPostComment_shouldThrowException_whenPostNotFound 댓글 생성 실패 - 존재하지 않는 게시글인 경우 예외가 발생해야 한다
softDeletePostComment_shouldChangeStatusToDeleted 댓글 삭제 테스트
softDeletePostComment_shouldThrowException_whenCommentNotFound 댓글 삭제 실패 - 존재하지 않는 댓글인 경우 예외가 발생해야 한다
softDeletePostComment_shouldThrowException_whenUserNotWriter 댓글 삭제 실패 - 작성자가 아닌 경우 예외가 발생해야 한다
deleteAllCommentsAndLikesByPostId_shouldDeleteAllComments 게시글 댓글 일괄 삭제 테스트

PostCommentLikeCommandServiceTest

테스트 메서드 시나리오
likePostComment_shouldCreateLike_whenUserNotLikedBefore 댓글 좋아요 테스트
likePostComment_shouldSkipSaving_whenUserAlreadyLiked 2. 이미 좋아요한 경우 중복 저장되지 않는지 검증
likePostComment_shouldThrow_whenCommentNotFound 실패
likePostComment_shouldThrow_whenCommentNotLikeable 2. 좋아요가 불가능한 댓글인 경우 예외가 발생하는지 검증
cancelPostCommentLike_shouldDelete_whenUserLiked 댓글 좋아요 취소 테스트
cancelPostCommentLike_shouldSkipDeletion_whenUserNotLiked 2. 좋아요하지 않은 상태에서 취소 시 삭제가 호출되지 않는지 검증
cancelPostCommentLike_shouldThrow_whenCommentNotFound 실패
cancelPostCommentLike_shouldThrow_whenCommentNotLikeable 2. 좋아요 취소가 불가능한 댓글인 경우 예외가 발생하는지 검증

PostCommentLikeQueryServiceTest

테스트 메서드 시나리오
getPostCommentLikers_shouldReturnPagedResponse_whenCommentActive 성공
getPostCommentLikers_shouldThrow_whenCommentNotFound 실패
getPostCommentLikers_shouldThrow_whenCommentNotAccessible 2. 댓글이 비활성화된 경우 예외가 발생하는지 검증

PostCommentQueryServiceTest

테스트 메서드 시나리오
getPostCommentDetailListForUser_shouldReturnPagedResponse_whenPostActive 성공
getPostCommentDetailListForUser_shouldThrow_whenPostNotFound 실패
getPostCommentDetailListForUser_shouldThrow_whenPostNotAccessible 2. 게시글이 비활성 상태인 경우 예외가 발생하는지 검증

PostImageUploadServiceTest

테스트 메서드 시나리오
uploadPostImages_shouldUploadAndPersistMetadata 성공
uploadPostImages_shouldThrow_whenImagesEmpty 실패
uploadPostImages_shouldThrow_whenImagesExceedLimit 2. 업로드 이미지가 허용 개수를 초과하면 예외가 발생하는지 검증

PostLikeCommandServiceTest

테스트 메서드 시나리오
likePost_shouldCreateLike_whenUserNotLikedBefore 게시글 좋아요 테스트
likePost_shouldSkipSaving_whenUserAlreadyLiked 2. 이미 좋아요한 경우 중복 저장되지 않는지 검증
likePost_shouldThrow_whenPostNotFound 실패
likePost_shouldThrow_whenPostNotLikable 2. 좋아요가 불가능한 게시글인 경우 예외가 발생하는지 검증
cancelLikePost_shouldDeleteLike_whenUserLikedBefore 게시글 좋아요 취소 테스트
cancelLikePost_shouldSkipDeletion_whenUserNotLiked 2. 좋아요하지 않은 상태에서 취소 시 삭제가 호출되지 않는지 검증
cancelLikePost_shouldThrow_whenPostNotFound 실패
cancelLikePost_shouldThrow_whenPostNotLikable 2. 좋아요 취소가 불가능한 게시글인 경우 예외가 발생하는지 검증

PostLikeQueryServiceTest

테스트 메서드 시나리오
getPostLikers_shouldReturnPagedResponse_whenPostExists 성공
getPostLikers_shouldThrow_whenPostNotFound 실패

PostQueryServiceTest

테스트 메서드 시나리오
getUserVisiblePostListByCursor_shouldReturnPagedResponse 게시글 목록 조회 테스트
getPost_shouldReturnDetails_whenPostActive 게시글 상세 조회 테스트
getPost_shouldThrow_whenPostNotFound 실패
getPost_shouldThrow_whenPostDeleted 2. 삭제된 게시글인 경우 예외가 발생하는지 검증
getPost_shouldThrow_whenPostArchived 3. 보관된 게시글인 경우 예외가 발생하는지 검증
getPost_shouldThrow_whenPostBlocked 4. 차단된 게시글인 경우 예외가 발생하는지 검증
getPostEngagement_shouldReturnProjection 게시글 참여도 조회 테스트
getPostEngagement_shouldThrow_whenPostNotFound 실패

ProfileImageCommandCommandServiceTest

테스트 메서드 시나리오
setMyProfileImage_shouldUploadAndSaveMetadata 프로필 이미지 업로드
updateProfileImage_shouldReplacePreviousImage 프로필 이미지 갱신
updateProfileImage_shouldDoNothing_whenSameImage 2. 기존 이미지와 동일한 경우 변경이 수행되지 않는지 검증
updateProfileImage_shouldDeletePrevious_whenNewImageNull 3. 새 이미지 없이 기존 이미지만 삭제하는 경우 동작을 검증
updateProfileImage_shouldThrow_whenImageNotExists 4. 존재하지 않는 이미지 id로 변경하려는 경우 예외가 발생하는지 검증

SearchPostQueryServiceTest

테스트 메서드 시나리오
searchByKeyword_shouldReturnPagedResponse_whenSortTypeSupported 성공
searchByKeyword_shouldThrow_whenSortTypeUnsupported 실패

SearchUserQueryServiceTest

테스트 메서드 시나리오
searchByKeyword_shouldReturnPagedResponse 사용자 검색
searchByKeyword_shouldMarkSelf_whenUserIncluded 2. 검색 결과에 본인이 포함되면 FOLLOW_STATUS가 SELF로 설정되는지 검증

UserCommandServiceTest

테스트 메서드 시나리오
register_shouldCreateNewUser_whenEmailNotExists 회원가입 테스트
register_shouldThrowException_whenEmailAlreadyExists 회원가입 실패 - 이미 존재하는 이메일인 경우 예외가 발생해야 한다
withdrawMyAccount_shouldChangeStatusToDeleted 계정 탈퇴 테스트
withdrawMyAccount_shouldThrowException_whenUserNotFound 계정 탈퇴 실패 - 존재하지 않는 사용자인 경우 예외가 발생해야 한다
deactivateMyAccount_shouldChangeStatusToInactive 계정 비활성화 테스트
changePassword_shouldUpdatePassword 비밀번호 변경 테스트

UserProfileCommandServiceTest

테스트 메서드 시나리오
registerMyProfile_shouldCreateProfile_whenNicknameNotDuplicated 프로필 생성 테스트
registerMyProfile_shouldThrowException_whenNicknameDuplicated 프로필 생성 실패 - 닉네임이 중복된 경우 예외가 발생해야 한다
updateMyProfile_shouldUpdateProfile_whenNicknameNotDuplicated 프로필 수정 테스트
updateMyProfile_shouldThrowException_whenNicknameDuplicated 프로필 수정 실패 - 닉네임이 중복된 경우 예외가 발생해야 한다

UserStatusValidatorTest

테스트 메서드 시나리오
validateUserStatusWithException_shouldPass_whenActive 성공
validateUserStatusWithException_shouldThrow_whenUserNotFound 실패
validateUserStatusWithException_shouldThrow_whenDeleted 2. DELETED 상태인 경우 예외가 발생하는지 검증
validateUserStatusWithException_shouldThrow_whenIncompleteProfile 3. INCOMPLETE_PROFILE 상태인 경우 예외가 발생하는지 검증
validateUserStatusWithException_shouldThrow_whenInactive 4. INACTIVE 상태인 경우 예외가 발생하는지 검증
threadly-commons · 테스트 클래스 5개 · 테스트 메서드 31개

JwtTokenProviderTest

테스트 메서드 시나리오
createAccessToken_shouldCreateTokenSuccessfully 토큰 생성 테스트
createRefreshToken_shouldCreateTokenSuccessfully createRefreshToken - refreshToken이 정상적으로 생성되어야 한다
createTokenWithPurpose_shouldCreateTokenSuccessfully createTokenWithPurpose - 목적이 있는 토큰이 정상적으로 생성되어야 한다
validateToken_shouldReturnTrue_whenTokenIsValid 토큰 검증 테스트
validateToken_shouldThrowException_whenTokenIsExpired validateToken - 만료된 토큰은 예외가 발생해야 한다
validateToken_shouldThrowException_whenTokenIsInvalid validateToken - 잘못된 토큰은 예외가 발생해야 한다
getUserId_shouldExtractUserId_whenTokenIsValid 토큰에서 정보 추출 테스트
getUserType_shouldExtractUserType_whenTokenIsValid getUserType - 토큰에서 userType을 정상적으로 추출해야 한다
getUserStatusType_shouldExtractUserStatusType_whenTokenIsValid getUserStatusType - 토큰에서 userStatusType을 정상적으로 추출해야 한다
extractAllInfo_shouldExtractAllInfoCorrectly_whenTokenIsValid 토큰에서 모든 정보를 올바르게 추출해야 한다
resolveToken_shouldExtractToken_whenAuthorizationHeaderIsValid resolveToken 테스트
resolveToken_shouldThrowException_whenAuthorizationHeaderIsMissing resolveToken - Authorization 헤더가 없는 경우 예외가 발생해야 한다
resolveToken_shouldThrowException_whenBearerPrefixIsMissing resolveToken - Bearer 접두사가 없는 경우 예외가 발생해야 한다
getAccessTokenTtl_shouldExtractTtl_whenTokenIsValid getAccessTokenTtl 테스트

JwtTokenUtilsTest

테스트 메서드 시나리오
extractAccessToken_shouldExtractToken_whenBearerTokenIsValid extractAccessToken 테스트
extractAccessToken_shouldThrowException_whenBearerPrefixIsMissing extractAccessToken - Bearer 접두사가 없는 경우 예외가 발생해야 한다
extractAccessToken_shouldThrowException_whenBearerTokenIsNull extractAccessToken - null인 경우 예외가 발생해야 한다
extractAccessToken_shouldThrowException_whenBearerTokenIsEmpty extractAccessToken - 빈 문자열인 경우 예외가 발생해야 한다
constructor_shouldThrowException_whenInstantiated 인스턴스화 불가 테스트

LogFormatUtilsTest

테스트 메서드 시나리오
getCaller_shouldReturnCallerInfo_whenCalled getCaller 테스트
getCaller_shouldNotReturnUnknownCaller_whenCalledNormally getCaller - UnknownCaller가 아닌 값이 반환되어야 한다
logSuccess_shouldNotThrowException_whenCalledWithMessage logSuccess 테스트
logFailure_shouldNotThrowException_whenCalledWithMessage logFailure 테스트

RandomUtilsTest

테스트 메서드 시나리오
generateUUIDTest UUID 생성 테스트
generateNanoIdTest NanoId 생성 테스트

TimeUtilsTest

테스트 메서드 시나리오
getExecutionTimeFormatted_shouldFormatCorrectly_whenOnlyMilliseconds getExecutionTimeFormatted 테스트
getExecutionTimeFormatted_shouldFormatCorrectly_whenOnlySeconds getExecutionTimeFormatted - 초만 있는 경우 올바르게 포맷팅되어야 한다
getExecutionTimeFormatted_shouldFormatCorrectly_whenOnlyMinutes getExecutionTimeFormatted - 분만 있는 경우 올바르게 포맷팅되어야 한다
getExecutionTimeFormatted_shouldFormatCorrectly_whenOnlyHours getExecutionTimeFormatted - 시간만 있는 경우 올바르게 포맷팅되어야 한다
getExecutionTimeFormatted_shouldFormatCorrectly_whenAllUnitsIncluded getExecutionTimeFormatted - 모든 단위가 포함된 경우 올바르게 포맷팅되어야 한다
getExecutionTimeFormatted_shouldFormatCorrectly_whenZeroTime getExecutionTimeFormatted - 0초인 경우 올바르게 포맷팅되어야 한다

notification-service

모듈 테스트 클래스 수 테스트 메서드 수
notification-commons 3 12
core-domain 1 2
core-port 1 2
core-service 7 32
adapter-redis 1 7
adapter-kafka 2 4
adapter-persistence 2 6
adapter-smtp 2 3
adapter-websocket 2 6
app-api 10 90
notification-commons · 테스트 클래스 3개 · 테스트 메서드 12개

JwtTokenProviderTest

테스트 메서드 시나리오
validateToken_shouldReturnTrue_whenTokenIsValid 1. 유효한 토큰이면 true가 반환되는지 검증
validateToken_shouldThrow_whenTokenIsExpired 2. 만료된 토큰이면 TOKEN_EXPIRED 예외가 발생하는지 검증
validateToken_shouldThrow_whenTokenIsInvalid 3. 잘못된 토큰이면 TOKEN_INVALID 예외가 발생하는지 검증
getUserId_shouldReturnValue_whenTokenIsValid 4. 유효한 토큰에서 userId가 올바르게 추출되는지 검증
getUserType_shouldReturnValue_whenTokenIsValid 5. 유효한 토큰에서 userType이 올바르게 추출되는지 검증
getUserStatusType_shouldReturnEnum_whenTokenIsValid 6. 유효한 토큰에서 userStatusType이 올바르게 추출되는지 검증

JwtTokenUtilsTest

테스트 메서드 시나리오
extractAccessToken_shouldReturnToken_whenBearerPrefixPresent 1. Bearer 접두사가 있는 경우 accessToken이 정상적으로 추출되는지 검증
extractAccessToken_shouldThrow_whenTokenIsNull 2. null 값이면 TOKEN_MISSING 예외가 발생하는지 검증
extractAccessToken_shouldThrow_whenPrefixMissing 3. Bearer 접두사가 없으면 TOKEN_MISSING 예외가 발생하는지 검증

ApiResponseTest

테스트 메서드 시나리오
success_shouldCreateResponse_whenDataProvided 1. 기본 success 응답이 올바르게 생성되는지 검증
success_shouldUseErrorCode_whenProvided 2. ErrorCode 기반 success 응답이 올바르게 생성되는지 검증
fail_shouldCreateResponse_whenErrorCodeProvided 3. 실패 응답이 올바르게 생성되는지 검증
core-domain · 테스트 클래스 1개 · 테스트 메서드 2개

NotificationTest

테스트 메서드 시나리오
newNotification_shouldInitializeFieldsCorrectly Notification 생성 성공 - 필드가 올바르게 초기화되어야 한다
markAsRead_shouldUpdateReadFlag 알림 읽음 처리 성공 - isRead 값이 true 로 변경되어야 한다
core-port · 테스트 클래스 1개 · 테스트 메서드 2개

NotificationDetailsTest

테스트 메서드 시나리오
cursorTimeStamp_shouldReturnOccurredAt 1. cursorTimeStamp 가 occurredAt 값을 반환하는지 검증
cursorId_shouldReturnSortId 2. cursorId 가 sortId 값을 반환하는지 검증
core-service · 테스트 클래스 7개 · 테스트 메서드 32개

NotificationCommandServiceTest

테스트 메서드 시나리오
ingest_shouldSaveAndPublishNotification 1. 알림을 저장하고 발행 이벤트가 전파되는지 검증
removeNotification_shouldDelete_whenNotificationExists 1. 알림이 존재하면 삭제가 수행되는지 검증
removeNotification_shouldThrow_whenNotificationNotFound 2. 알림이 존재하지 않으면 예외가 발생하는지 검증
clearNotifications_shouldDeleteAllByReceiver 1. 사용자 알림 전체 삭제가 수행되는지 검증
markNotificationAsRead_shouldUpdateNotification 1. 알림을 읽음 처리한 뒤 저장하는지 검증
markNotificationAsRead_shouldThrow_whenNotificationMissing 2. 알림이 존재하지 않으면 예외가 발생하는지 검증
markAllNotificationsAsRead_shouldDelegateToPort 1. 사용자 알림 전체 읽음 처리가 수행되는지 검증

NotificationQueryQueryServiceTest

테스트 메서드 시나리오
findNotificationDetail_shouldReturnResponse_whenNotificationExists 1. 알림 상세 조회가 성공적으로 수행되는지 검증
findNotificationDetail_shouldThrow_whenEventIdEmpty 2. eventId가 비어있으면 INVALID_REQUEST 예외가 발생하는지 검증
findNotificationDetail_shouldThrow_whenNotificationMissing 3. 알림이 존재하지 않으면 NOTIFICATION_NOT_FOUND 예외가 발생하는지 검증
findNotificationDetail_shouldThrow_whenReceiverMismatch 4. 다른 사용자의 알림이면 NOTIFICATION_ACCESS_FORBIDDEN 예외가 발생하는지 검증
findNotificationByCursor_shouldReturnPagedResult 1. 커서 조회 시 limit 기준으로 응답이 생성되는지 검증
findUnreadNotificationByCursor_shouldReturnPagedResult 1. 미확인 알림 커서 조회 결과가 반환되는지 검증

NotificationDeliveryServiceTest

테스트 메서드 시나리오
pushNotification_shouldCreatePostLikePreview_whenTypeIsPostLike 1. POST_LIKE 타입일 때 PostLikePreview가 생성되는지 검증
pushNotification_shouldCreatePostCommentPreview_whenTypeIsCommentAdded 2. COMMENT_ADDED 타입일 때 PostCommentPreview가 생성되는지 검증
pushNotification_shouldCreateCommentLikePreview_whenTypeIsCommentLike 3. COMMENT_LIKE 타입일 때 CommentLikePreview가 생성되는지 검증
pushNotification_shouldCreateFollowPreview_whenTypeIsFollow 4. FOLLOW 타입일 때 FollowPreview가 생성되는지 검증
pushNotification_shouldCreateFollowRequestPreview_whenTypeIsFollowRequest 5. FOLLOW_REQUEST 타입일 때 FollowRequestPreview가 생성되는지 검증
pushNotification_shouldCreateFollowAcceptPreview_whenTypeIsFollowAccept 6. FOLLOW_ACCEPT 타입일 때 FollowAcceptPreview가 생성되는지 검증

NotificationEventListenerTest

테스트 메서드 시나리오
onNotificationPublished_shouldDelegateToDeliveryService 1. 알림 발송 서비스에 위임되는지 검증
onNotificationPublished_shouldPropagateException_whenDeliveryFails 2. 발송 중 예외가 발생하면 그대로 전파되는지 검증

SendMailServiceTest

테스트 메서드 시나리오
send_shouldDispatchWelcomeMail_whenTypeIsWelcome 1. 가입 환영 메일이 정상적으로 전송되는지 검증
send_shouldDispatchVerificationMail_whenTypeIsVerification 1. 인증 메일이 정상적으로 전송되는지 검증
send_shouldThrowEmailVerificationException_whenMailSendingFails 2. 메일 전송 실패 시 EMAIL_SENDING_FAILED 예외가 발생하는지 검증

MailModelMapperTest

테스트 메서드 시나리오
toTypeModel_shouldConvertToWelcomeModel_whenTypeIsWelcome 1. WELCOME 타입이면 WelcomeModel로 변환되는지 검증
toTypeModel_shouldConvertToVerificationModel_whenTypeIsVerification 2. VERIFICATION 타입이면 VerificationModel로 변환되는지 검증

MetadataMapperTest

테스트 메서드 시나리오
toTypeMeta_shouldMapToPostLikeMeta 1. POST_LIKE 타입이면 PostLikeMeta로 변환되는지 검증
toTypeMeta_shouldMapToPostCommentMeta 2. COMMENT_ADDED 타입이면 PostCommentMeta로 변환되는지 검증
toTypeMeta_shouldMapToCommentLikeMeta 3. COMMENT_LIKE 타입이면 CommentLikeMeta로 변환되는지 검증
toTypeMeta_shouldMapToFollowRequestMeta 4. FOLLOW_REQUEST 타입이면 FollowRequestMeta로 변환되는지 검증
toTypeMeta_shouldMapToFollowAcceptMeta 5. FOLLOW_ACCEPT 타입이면 FollowAcceptMeta로 변환되는지 검증
toTypeMeta_shouldMapToFollowMeta 6. FOLLOW 타입이면 FollowMeta로 변환되는지 검증
adapter-redis · 테스트 클래스 1개 · 테스트 메서드 7개

TokenRepositoryTest

테스트 메서드 시나리오
existsBlackListTokenByAccessToken_WhenTokenExists_ShouldReturnTrue 1. 블랙리스트에 등록된 AccessToken이 존재하는지 조회 - 존재하는 경우
existsBlackListTokenByAccessToken_WhenTokenNotExists_ShouldReturnFalse 2. 블랙리스트에 등록된 AccessToken이 존재하는지 조회 - 존재하지 않는 경우
existsBlackListTokenByAccessToken_ShouldUseCorrectKeyFormat 3. 블랙리스트 토큰 키 생성 검증
existsBlackListTokenByAccessToken_WithEmptyToken_ShouldReturnFalse 4. 빈 문자열 AccessToken 처리
existsBlackListTokenByAccessToken_WithNullToken_ShouldHandleGracefully 5. null AccessToken 처리
existsBlackListTokenByAccessToken_MultipleTokens_ShouldWorkCorrectly 6. 여러 토큰 블랙리스트 등록 및 조회
existsBlackListTokenByAccessToken_WhenTtlExpired_ShouldReturnFalse 7. TTL 만료 후에는 블랙리스트 토큰 조회가 false 를 반환한다
adapter-kafka · 테스트 클래스 2개 · 테스트 메서드 4개

NotificationConsumerTest

테스트 메서드 시나리오
notificationEventConsumer_shouldIngest_whenKeyMatchesReceiver 1. key가 receiverId와 같으면 ingest가 호출되는지 검증
notificationEventConsumer_shouldSkipIngest_whenKeyMismatch 2. key가 receiverId와 다르면 ingest가 호출되지 않는지 검증

MailConsumerTest

테스트 메서드 시나리오
mailEventConsumer_shouldSendMail_whenKeyMatchesReceiver 1. key가 수신자와 일치하면 메일 전송이 수행되는지 검증
mailEventConsumer_shouldSkipMail_whenKeyMismatch 2. key가 수신자와 다르면 메일 전송이 호출되지 않는지 검증
adapter-persistence · 테스트 클래스 2개 · 테스트 메서드 6개

NotificationMapperTest

테스트 메서드 시나리오
toEntity_shouldMapDomainToDoc 1. 도메인이 엔티티로 올바르게 변환되는지 검증
toDomain_shouldMapDocToDomain 1. 엔티티가 도메인으로 올바르게 변환되는지 검증

NotificationPersistenceAdapterTest

테스트 메서드 시나리오
save_shouldPersistNotification 1. 알림을 저장하고 SavedNotificationEventDoc이 반환되는지 검증
fetchByEventId_shouldReturnDomain 1. 저장된 알림을 도메인으로 변환하여 반환하는지 검증
fetchAllByCursor_shouldMapDocsToDetails 1. 커서 조회 결과가 NotificationDetails 리스트로 매핑되는지 검증
markAsRead_shouldUpdateRepository 1. 알림 읽음 상태 업데이트가 수행되는지 검증
adapter-smtp · 테스트 클래스 2개 · 테스트 메서드 3개

MailClientTest

테스트 메서드 시나리오
sendMail_shouldInvokeJavaMailSender 1. 메일 전송이 성공적으로 수행되는지 검증
sendMail_shouldThrowEmailVerificationException_whenSendFails 2. 메일 전송 중 예외 발생 시 EMAIL_SENDING_FAILED 예외가 발생하는지 검증

MailSmtpAdapterTest

테스트 메서드 시나리오
sendMail_shouldDelegateToMailClient 1. MailClient 에게 메일 전송이 위임되는지 검증
adapter-websocket · 테스트 클래스 2개 · 테스트 메서드 6개

WebSocketPushAdapterTest

테스트 메서드 시나리오
pushToUser_shouldEmitSerializedJson_whenSerializationSucceeds 1. 직렬화가 성공하면 세션 레지스트리에 JSON이 전파되는지 검증
pushToUser_shouldEmitFallbackJson_whenSerializationFails 2. 직렬화가 실패하면 기본 JSON으로 전파되는지 검증

WsSessionRegistryTest

테스트 메서드 시나리오
addAndRemove_shouldManageSessions 1. 세션 등록과 제거가 정상적으로 동작하는지 검증
emit_shouldSendMessageToOpenSession 1. 열린 세션에는 메시지가 전송되는지 검증
emit_shouldRemoveClosedSession 2. 닫힌 세션은 제거되는지 검증
emit_shouldRemoveSession_whenSendFails 3. 전송 중 IOException 발생 시 세션이 제거되는지 검증
app-api · 테스트 클래스 10개 · 테스트 메서드 90개

DeleteAllNotificationsApiTest

테스트 메서드 시나리오
deleteAllNotifications_WithMultipleNotifications_ShouldReturnSuccess 1. 여러 알림 전체 삭제 - 성공
deleteAllNotifications_WithNoNotifications_ShouldReturnSuccess 2. 알림이 없는 상태에서 전체 삭제 - 성공 (Idempotent)
deleteAllNotifications_ShouldNotDeleteOtherUsersNotifications 3. 다른 사용자의 알림은 삭제되지 않음 - 성공
deleteAllNotifications_WithoutAuthentication_ShouldReturnBadRequest 4. 인증 없이 전체 알림 삭제 - 400 Bad Request
deleteAllNotifications_WithExpiredToken_ShouldReturnUnauthorized 5. 만료된 토큰으로 전체 알림 삭제 - 401 Unauthorized
deleteAllNotifications_WithPartialNotifications_ShouldDeleteAll 6. 부분적으로 알림이 있는 상태에서 전체 삭제 - 성공
deleteAllNotifications_AfterAlreadyDeleted_ShouldReturnSuccess 7. 전체 삭제 후 다시 전체 삭제 - 성공 (Idempotent)
deleteAllNotifications_WithLargeAmountOfNotifications_ShouldReturnSuccess 8. 대량의 알림 전체 삭제 - 성공
deleteAllNotifications_WithMixedNotificationTypes_ShouldDeleteAll 9. 혼합된 알림 타입의 전체 삭제 - 성공
deleteAllNotifications_PerformanceAndStabilityTest 10. 전체 삭제 성능 및 안정성 검증

DeleteNotificationApiTest

테스트 메서드 시나리오
deleteNotification_ExistingNotification_ShouldReturnSuccess 1. 존재하는 알림 삭제 - 성공
deleteNotification_NonExistentNotification_ShouldReturnNotFound 2. 존재하지 않는 알림 삭제 - 404 Not Found
deleteNotification_OtherUserNotification_ShouldReturnNotFound 3. 다른 사용자의 알림 삭제 - 404 NotFound
deleteNotification_WithoutAuthentication_ShouldReturnBadRequest 4. 인증 없이 알림 삭제 - 400 Bad Request
deleteNotification_WithExpiredToken_ShouldReturnUnauthorized 5. 만료된 토큰으로 알림 삭제 - 401 Unauthorized
deleteNotification_WithSpecialCharacterEventId_ShouldReturnNotFound 6. 특수 문자가 포함된 eventId로 알림 삭제 - 404 Not Found
deleteNotification_MultipleNotificationsExist_ShouldDeleteOnlyTargetOne 7. 여러 알림 중 특정 알림만 삭제 - 성공
deleteNotification_AlreadyDeletedNotification_ShouldReturnNotFound 8. 이미 삭제된 알림 재삭제 시도 - 404 Not Found
deleteNotification_AuthorizedUser_ShouldCompletelyRemoveData 9. 권한이 있는 사용자의 알림 삭제 후 데이터 완전 제거 검증

GetNotificationApiTest

테스트 메서드 시나리오
getNotificationDetail_ExistingNotification_ShouldReturnSuccess 1. 존재하는 알림 조회 - 성공
getNotificationDetail_NonExistentNotification_ShouldReturnNotFound 2. 존재하지 않는 알림 조회 - 404 Not Found
getNotificationDetail_OtherUserNotification_ShouldReturnForbidden 3. 다른 사용자의 알림 조회 - 403 Forbidden
getNotificationDetail_WithoutAuthentication_ShouldReturnBadRequest 4. 인증 없이 알림 조회 - 400 Bad Request
getNotificationDetail_WithExpiredToken_ShouldReturnUnauthorized 5. 만료된 토큰으로 알림 조회 - 401 Unauthorized
getNotificationDetail_WithSpecialCharacterEventId_ShouldReturnNotFound 6. 특수 문자가 포함된 eventId로 알림 조회 - 404 Not Found
getNotificationDetail_MultipleNotificationsExist_ShouldReturnCorrectOne 7. 여러 알림 중 특정 알림 조회 - 성공
getNotificationDetail_DifferentNotificationTypes_ShouldReturnSuccess 8. 다양한 알림 타입 조회 - 성공
getNotificationDetail_WithMetadata_ShouldReturnCorrectMetadata 9. 정상적인 메타데이터 조회 - 성공
getNotificationDetail_WithDifferentActorProfile_ShouldReturnCorrectProfile 10. 다양한 ActorProfile 정보가 포함된 알림 조회 - 성공
getNotificationDetail_WithNullActorProfile_ShouldHandleGracefully 11. null ActorProfile로 알림 조회 - ActorProfile 필드 검증

GetNotificationsByCursorApiTest

테스트 메서드 시나리오
getNotifications_WithoutParams_ShouldReturnSuccess 1. 기본 알림 목록 조회 (파라미터 없음) - 성공
getNotifications_WithLimit_ShouldReturnLimitedResults 2. limit 파라미터로 알림 목록 조회 - 성공
getNotifications_WithCursor_ShouldReturnNextPage 3. 커서 기반 페이지네이션 조회 - 성공
getNotifications_ShouldNotReturnOtherUsersNotifications 4. 다른 사용자의 알림은 조회되지 않음 - 성공
getNotifications_WithNoNotifications_ShouldReturnEmptyList 5. 빈 결과 조회 - 성공
getNotifications_WithoutAuthentication_ShouldReturnBadRequest 6. 인증 없이 알림 목록 조회 - 400 Bad Request
getNotifications_WithExpiredToken_ShouldReturnUnauthorized 7. 만료된 토큰으로 알림 목록 조회 - 401 Unauthorized
getNotifications_WithLargeLimit_ShouldReturnSuccess 8. 큰 limit 값으로 조회 - 성공
getNotifications_WithActorProfile_ShouldReturnCorrectProfile 9. ActorProfile 정보가 포함된 알림 목록 조회 - 성공
getNotifications_ShouldReturnInTimeOrder 10. 시간순 정렬 검증 - 성공

GetUnreadNotificationsByCursorApiTest

테스트 메서드 시나리오
getUnreadNotifications_WithoutParams_ShouldReturnSuccess 1. 기본 읽지 않은 알림 목록 조회 (파라미터 없음) - 성공
getUnreadNotifications_WithLimit_ShouldReturnLimitedResults 2. limit 파라미터로 읽지 않은 알림 목록 조회 - 성공
getUnreadNotifications_WithCursor_ShouldReturnNextPage 3. 커서 기반 페이지네이션으로 읽지 않은 알림 조회 - 성공
getUnreadNotifications_ShouldNotReturnOtherUsersNotifications 4. 다른 사용자의 읽지 않은 알림은 조회되지 않음 - 성공
getUnreadNotifications_WithNoUnreadNotifications_ShouldReturnEmptyList 5. 읽지 않은 알림이 없는 경우 - 빈 결과 반환
getUnreadNotifications_WithNoNotifications_ShouldReturnEmptyList 6. 알림이 전혀 없는 경우 - 빈 결과 반환
getUnreadNotifications_WithoutAuthentication_ShouldReturnBadRequest 7. 인증 없이 읽지 않은 알림 목록 조회 - 400 Bad Request
getUnreadNotifications_WithExpiredToken_ShouldReturnUnauthorized 8. 만료된 토큰으로 읽지 않은 알림 목록 조회 - 401 Unauthorized
getUnreadNotifications_WithMixedReadStatus_ShouldReturnOnlyUnread 9. 읽음 상태 혼재 시 읽지 않은 알림만 조회 - 성공
getUnreadNotifications_ShouldReturnInTimeOrder 10. 시간순 정렬 검증 - 읽지 않은 알림만 최신순으로 정렬
getUnreadNotifications_WithActorProfile_ShouldReturnCorrectProfile 11. ActorProfile 정보가 포함된 읽지 않은 알림 조회 - 성공

MarkAllAsReadNotificationsApiTest

테스트 메서드 시나리오
markAllAsReadNotifications_WithUnreadNotifications_ShouldReturnSuccess 1. 여러 읽지 않은 알림 전체 읽음 처리 - 성공
markAllAsReadNotifications_WithNoNotifications_ShouldReturnSuccess 2. 알림이 없는 상태에서 전체 읽음 처리 - 성공 (Idempotent)
markAllAsReadNotifications_WithAllReadNotifications_ShouldReturnSuccess 3. 이미 모든 알림이 읽음 상태에서 전체 읽음 처리 - 성공 (Idempotent)
markAllAsReadNotifications_ShouldNotMarkOtherUsersNotifications 4. 다른 사용자의 알림은 읽음 처리되지 않음 - 성공
markAllAsReadNotifications_WithoutAuthentication_ShouldReturnBadRequest 5. 인증 없이 전체 읽음 처리 - 400 Bad Request
markAllAsReadNotifications_WithExpiredToken_ShouldReturnUnauthorized 6. 만료된 토큰으로 전체 읽음 처리 - 401 Unauthorized
markAllAsReadNotifications_WithMixedReadStatus_ShouldMarkAllAsRead 7. 혼합된 읽음 상태의 알림들 전체 읽음 처리 - 성공
markAllAsReadNotifications_WithLargeAmountOfNotifications_ShouldReturnSuccess 8. 대량의 알림 전체 읽음 처리 - 성공
markAllAsReadNotifications_AfterMarkingAllAsRead_ShouldShowAllReadInList 9. 전체 읽음 처리 후 목록 조회에서 모든 알림이 읽음 상태 - 성공
markAllAsReadNotifications_PerformanceAndStabilityTest 10. 전체 읽음 처리 성능 및 안정성 검증

MarkAsReadNotificationApiTest

테스트 메서드 시나리오
markAsReadNotification_UnreadNotification_ShouldReturnSuccess 1. 읽지 않은 알림 읽음 처리 - 성공
markAsReadNotification_AlreadyReadNotification_ShouldReturnSuccess 2. 이미 읽은 알림 읽음 처리 - 성공 (Idempotent)
markAsReadNotification_NonExistentNotification_ShouldReturnNotFound 3. 존재하지 않는 알림 읽음 처리 - 404 Not Found
markAsReadNotification_OtherUserNotification_ShouldReturnNotFound 4. 다른 사용자의 알림 읽음 처리 - 404 NotFound
markAsReadNotification_WithoutAuthentication_ShouldReturnBadRequest 5. 인증 없이 알림 읽음 처리 - 400 Bad Request
markAsReadNotification_WithExpiredToken_ShouldReturnUnauthorized 6. 만료된 토큰으로 알림 읽음 처리 - 401 Unauthorized
markAsReadNotification_MultipleNotificationsExist_ShouldMarkOnlyTargetOne 7. 여러 알림 중 특정 알림만 읽음 처리 - 성공
markAsReadNotification_AfterMarkingAsRead_ShouldPersistReadStatus 8. 읽음 처리 후 데이터 영속성 검증

NotificationKafkaIntegrationTest

테스트 메서드 시나리오
kafkaIntegration_PostLikeEvent_ShouldSaveToDatabase 1. POST_LIKE 이벤트 수신 및 DB 저장 - 성공
kafkaIntegration_SavedNotificationApiVerification_ShouldReturnCorrectData 2. 저장된 알림 API 조회로 검증 - 성공
kafkaIntegration_MultipleEvents_ShouldSaveAllAndRetrieveIndividually 3. 다중 이벤트 수신 및 개별 조회 - 성공
kafkaIntegration_InvalidEventData_ShouldHandleGracefully 4. 잘못된 이벤트 데이터 처리 - Kafka 발신 성공하지만 저장 실패
kafkaIntegration_DuplicateEventId_ShouldHandleIdempotently 5. 동일한 eventId 중복 이벤트 처리 - 멱등성 확인
kafkaIntegration_BulkEvents_ShouldProcessAllSuccessfully 6. 대용량 이벤트 처리 - 성능 및 안정성 검증

NotificationMetadataSerializationTest

테스트 메서드 시나리오
testPostLikeMetadata POST_LIKE 메타데이터 저장 및 조회 테스트
testCommentAddedMetadata COMMENT_ADDED 메타데이터 저장 및 조회 테스트
testCommentLikeMetadata COMMENT_LIKE 메타데이터 저장 및 조회 테스트
testFollowRequestMetadata FOLLOW_REQUEST 메타데이터 저장 및 조회 테스트
testFollowMetadata FOLLOW 메타데이터 저장 및 조회 테스트
testFollowAcceptMetadata FOLLOW_ACCEPT 메타데이터 저장 및 조회 테스트

SecurityApiTest

테스트 메서드 시나리오
testValidAccessToken Security API 인증 테스트
testNoAuthorizationHeader 2. AccessToken이 없는 경우 - 400 Unauthorized
testInvalidAccessTokenFormat 3. 잘못된 형식의 AccessToken - 401 Unauthorized
testTokenWithoutBearer 4. Bearer 없이 토큰만 전송하는 경우 - 400 BadRequest
testExpiredAccessToken 5. 만료된 AccessToken - 401 Unauthorized
testBlacklistedAccessToken 6. 블랙리스트에 등록된 AccessToken - 400 BadRequest
testInvalidSignatureAccessToken 7. 잘못된 서명을 가진 AccessToken - 400 Bad Request
testEmptyAccessToken 8. 빈 문자열 AccessToken - 400 BadRequest
testMultipleValidRequests 9. 여러 번의 정상적인 요청 - 성공
core-domain · 테스트 클래스 1개 · 테스트 메서드 2개

NotificationTest

테스트 메서드 시나리오
newNotification_shouldInitializeFieldsCorrectly Notification 생성 테스트
markAsRead_shouldUpdateReadFlag Notification 읽음 처리 테스트
⚠️ **GitHub.com Fallback** ⚠️