Skip to content

Conversation

@nayonsoso
Copy link
Collaborator

  • 레이어드 아키텍쳐의 구조에 맞게, 컨트롤러 테스트가 아닌 테스트 코드에서 "응답"이라는 단어를 쓰지 않는다.

관련 이슈

작업 내용

예외_응답을_반환한다였던 함수명을 예외가_발생한다로 바꿉니다.

레이어드 아키텍처에 따르면, 서비스 코드에서의 예외는 발생하는 것이지 "응답"되는 것이 아닙니다.
응답은 컨트롤러의 관심사입니다.

- 레이어드 아키텍쳐의 구조에 맞게, 컨트롤러 테스트가 아닌 테스트 코드에서 "응답"이라는 단어를 쓰지 않는다.
@coderabbitai
Copy link

coderabbitai bot commented Jul 13, 2025

Walkthrough

  1. 테스트 메서드 이름 일괄 변경
      - 전체 테스트 코드에서 "예외_응답을_반환한다"라는 문구가 포함된 테스트 메서드 이름을 "예외가_발생한다"로 변경하였습니다.
       - 예시: 예외_응답을_반환한다()예외가_발생한다()
       - 이 변경은 관리자 서비스, 인증, 커뮤니티, 멘토링, 대학 지원 등 다양한 도메인의 테스트 클래스 및 내부 중첩 클래스에 걸쳐 적용되었습니다.
       - 테스트의 실제 로직, 예외 발생 조건, 검증 방식 등은 전혀 수정되지 않았으며, 오직 메서드 시그니처(이름)만 변경되었습니다.

  2. 중첩 테스트 클래스 이름 변경
      - 일부 테스트 클래스의 중첩 클래스명도 "예외_응답을_반환한다"에서 "예외가_발생한다" 또는 "예외_발생" 등으로 변경되었습니다.

  3. 테스트 목적 표현 방식 통일
      - 모든 예외 상황 테스트의 이름을 "예외가_발생한다"로 통일하여, 테스트 목적을 더 직접적이고 일관성 있게 표현하도록 정리하였습니다.

  4. 기타
      - 테스트의 접근 제한자, 파라미터, 예외 타입, 검증 메시지 등은 일절 변경되지 않았습니다.
      - 실제 서비스 코드나 비즈니스 로직에는 영향이 없으며, 테스트 코드의 가독성과 명확성을 위한 네이밍 리팩터링입니다.


📜 Recent review details

Configuration used: CodeRabbit UI
Review profile: CHILL
Plan: Pro

📥 Commits

Reviewing files that changed from the base of the PR and between 1f08f38 and fcd6c55.

📒 Files selected for processing (2)
  • src/test/java/com/example/solidconnection/community/comment/service/CommentServiceTest.java (5 hunks)
  • src/test/java/com/example/solidconnection/security/provider/SiteUserAuthenticationProviderTest.java (3 hunks)
🚧 Files skipped from review as they are similar to previous changes (2)
  • src/test/java/com/example/solidconnection/security/provider/SiteUserAuthenticationProviderTest.java
  • src/test/java/com/example/solidconnection/community/comment/service/CommentServiceTest.java
⏰ Context from checks skipped due to timeout of 90000ms. You can increase the timeout in your CodeRabbit configuration to a maximum of 15 minutes (900000ms). (1)
  • GitHub Check: build
✨ Finishing Touches
  • 📝 Generate Docstrings

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
🪧 Tips

Chat

There are 3 ways to chat with CodeRabbit:

  • Review comments: Directly reply to a review comment made by CodeRabbit. Example:
    • I pushed a fix in commit <commit_id>, please review it.
    • Explain this complex logic.
    • Open a follow-up GitHub issue for this discussion.
  • Files and specific lines of code (under the "Files changed" tab): Tag @coderabbitai in a new review comment at the desired location with your query. Examples:
    • @coderabbitai explain this code block.
    • @coderabbitai modularize this function.
  • PR comments: Tag @coderabbitai in a new PR comment to ask questions about the PR branch. For the best results, please provide a very specific query, as very limited context is provided in this mode. Examples:
    • @coderabbitai gather interesting stats about this repository and render them as a table. Additionally, render a pie chart showing the language distribution in the codebase.
    • @coderabbitai read src/utils.ts and explain its main purpose.
    • @coderabbitai read the files in the src/scheduler package and generate a class diagram using mermaid and a README in the markdown format.
    • @coderabbitai help me debug CodeRabbit configuration file.

Support

Need help? Create a ticket on our support page for assistance with any issues or questions.

Note: Be mindful of the bot's finite context window. It's strongly recommended to break down tasks such as reading entire modules into smaller chunks. For a focused discussion, use review comments to chat about specific files and their changes, instead of using the PR comments.

CodeRabbit Commands (Invoked using PR comments)

  • @coderabbitai pause to pause the reviews on a PR.
  • @coderabbitai resume to resume the paused reviews.
  • @coderabbitai review to trigger an incremental review. This is useful when automatic reviews are disabled for the repository.
  • @coderabbitai full review to do a full review from scratch and review all the files again.
  • @coderabbitai summary to regenerate the summary of the PR.
  • @coderabbitai generate docstrings to generate docstrings for this PR.
  • @coderabbitai generate sequence diagram to generate a sequence diagram of the changes in this PR.
  • @coderabbitai resolve resolve all the CodeRabbit review comments.
  • @coderabbitai configuration to show the current CodeRabbit configuration for the repository.
  • @coderabbitai help to get help.

Other keywords and placeholders

  • Add @coderabbitai ignore anywhere in the PR description to prevent this PR from being reviewed.
  • Add @coderabbitai summary to generate the high-level summary at a specific location in the PR description.
  • Add @coderabbitai anywhere in the PR title to generate the title automatically.

CodeRabbit Configuration File (.coderabbit.yaml)

  • You can programmatically configure CodeRabbit by adding a .coderabbit.yaml file to the root of your repository.
  • Please see the configuration documentation for more information.
  • If your editor has YAML language server enabled, you can add the path at the top of this file to enable auto-completion and validation: # yaml-language-server: $schema=https://coderabbit.ai/integrations/schema.v2.json

Documentation and Community

  • Visit our Documentation for detailed information on how to use CodeRabbit.
  • Join our Discord Community to get help, request features, and share feedback.
  • Follow us on X/Twitter for updates and announcements.

@nayonsoso nayonsoso self-assigned this Jul 13, 2025
Copy link
Member

@whqtker whqtker left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

확인했습니다 !

Copy link
Contributor

@Gyuhyeok99 Gyuhyeok99 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

고생하셨습니다!! 간단한 리뷰만 남겨놓았으니 승인해두겠습니다!


@Test
void 대대댓글_생성_시도하면_예외_응답을_반환한다() {
void 대대댓글_생성_시도하면_예외가_발생한다() {
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

253번라인은 반환한다로 되어있습니다!

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

반영했습니다~


@Nested
class 예외_응답을_반환하다 {
class 예외_발생 {
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

이것만 예외_발생으로 되어있는데 발생한다로 통일하는 거 어떤가요?

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

반영했습니다. 꼼꼼히 확인해주셔서 감사해요 🥹

@nayonsoso nayonsoso merged commit efc32cc into solid-connection:develop Jul 14, 2025
2 checks passed

@Test
void 존재하지_않는_부모댓글로_대댓글_작성시_예외를_반환한다() {
void 존재하지_않는_부모댓글로_대댓글_작성시_예외가_빌생한다() {
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

앗 여기 오타가 .... 🥲

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

으앗 엄청 열심히 봤는데 저도 놓쳤나보네요.....

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.

refactor: 예외 발생 테스트의 함수명 수정

3 participants