WISH-441 - src/event-handlers/ refactoring && fix failing tests #237
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.
이벤트 핸들러 모듈 리팩토링 및 실패하는 테스트 수정
변경 사항:
이벤트 핸들러 모듈 구조 개선
src/event-handlers내부의 이벤트 핸들러들을 각 도메인별 하위 디렉토리로 이동 (deposit/,donation/,provisional-donation/)Funding Entity 테스트 코드 개선
isClosed메서드의 테스트에서 과거 날짜를 설정하는 방식 변경pastDate.setDate(pastDate.getDate() - 1);new Date('1000-01-01')사용 → 더욱 명확한 과거 날짜 지정Deposit 및 Donation 관련 이벤트 핸들러 리팩토링
DepositDeleteSaga,DepositEventHandler,DonationEventHandler,ProvisionalDonationEventHandler등 이벤트 핸들러의 의존성 및 모듈 import 정리DonationEventHandler의 Admin 알림 제거)DeleteDepositUseCase및DecreaseFundSumUseCase실행 부분을 주석 처리하고 관련 로직을DeleteDepositSaga로 이동테스트 코드 리팩토링 및 버그 수정
DepositDeleteSaga및 관련 테스트에서 불필요한 import 정리MatchDepositUseCase에서deposit.transition을 Mock 처리하여 테스트 안정성 강화image-query.spec.ts에서 TypeORMquery이벤트 리스너 관련 컴파일 오류 발생 코드 주석 처리 (!FIXME추가)변경 이유:
isClosed테스트 개선을 통해 가독성을 높이고 명확한 테스트를 수행검토 요청:
DonationEventHandler에서 Admin 알림 제거가 비즈니스 로직상 문제가 없는지 검토 바랍니다.funding.entity.spec: