Skip to content

Conversation

@B1uffer
Copy link

@B1uffer B1uffer commented Nov 9, 2025

요구사항

기본

  • 기본 항목 1
  • 기본 항목 2

심화

  • 심화 항목 1
  • 심화 항목 2

주요 변경사항

스크린샷

image

멘토에게

  • 아 너무 어렵습니다 꾸준히 공부하겠습니다

@Controller
public class MessageWebSocketController {
// 첨부파일이 없는 단순 텍스트 메시지인 경우 STOMP를 통해 메시지를 전송할 수 있도록 컨트롤러 구현
private final SimpMessagingTemplate messageTemplate;
Copy link
Collaborator

@spring-kang spring-kang Nov 12, 2025

Choose a reason for hiding this comment

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

SimpMessagingTemplate 이걸 서비스나 리스너 등에 주입받도록 구현하시는게 훨씬 책임이 분리된 로직으로 보입니다.

@RestController
@RequiredArgsConstructor
public class SseController {
private final SseEmitterRepository emitterRepository;
Copy link
Collaborator

Choose a reason for hiding this comment

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

SseEmitterRepository 가 여기서 직접 주입되어 구현되면 안됩니다. 해당 로직은 sse service에서 구현하는 방향으로 변경해보세요!

@spring-kang spring-kang requested a review from Copilot November 12, 2025 02:13
Copy link

Copilot AI left a comment

Choose a reason for hiding this comment

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

Pull Request Overview

This PR implements comprehensive test coverage for a Discord-like application including unit tests, integration tests, and test infrastructure configuration. The changes add testing for all major service layers, controllers, repositories, security components, and event listeners.

Key Changes

  • Added extensive unit test coverage for service layer components (User, Message, Channel, Notification, BinaryContent, ReadStatus, Auth services)
  • Implemented integration tests for API endpoints and business workflows
  • Added test configuration files and test-specific application settings
  • Created tests for storage implementations (S3 and local), security/JWT components, and event listeners

Reviewed Changes

Copilot reviewed 195 out of 201 changed files in this pull request and generated no comments.

Show a summary per file
File Description
src/test/resources/application-test.yaml Test environment configuration with H2 database and test-specific JWT settings
src/test/java/.../storage/s3/* S3 storage integration tests for file upload/download operations
src/test/java/.../service/basic/* Unit tests for all basic service implementations using Mockito
src/test/java/.../security/* Tests for JWT authentication, login flow, and CSRF protection
src/test/java/.../repository/* Repository layer tests with @DataJpaTest for database operations
src/test/java/.../integration/* End-to-end API integration tests for all major features
src/test/java/.../event/listener/* Event listener tests for notification and binary content events
src/test/java/.../controller/* Controller layer tests with MockMvc for HTTP endpoint validation
src/main/resources/static/* Static frontend assets (index.html, CSS bundle)
src/main/resources/*.yaml Application configuration files for dev, prod, and base profiles
src/main/resources/schema.sql Database schema definition with tables and constraints
src/main/resources/logback-spring.xml Logging configuration with MDC support
src/main/java/.../storage/* Storage implementation interfaces and S3/local implementations
src/main/java/.../service/basic/* Service implementations with SSE support and caching
settings.gradle Gradle project configuration

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

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.

2 participants