인터페이스는 현지화되어 있으며, Skill 소개와 설명 문서는 선택한 언어로 AI가 자동 번역합니다. 코드·명령어·경로·전문 용어는 원문을 유지하며 원작자 문서가 우선합니다.
Skills 둘러보기
데이터 및 연구 · SKILL.md

spring-mvc-testing

spring-mvc-testing

Boot 4+ replaced MockMvc assertions with MockMvcTester — incompatible API your training data gets wrong. Read before writing any @WebMvcTest. Triggers: @WebMvcTest, MockMvc, MockMvcTester, @RestController, jsonPath, @GetMapping, @PostMapping, @AutoConfigureMockMvc, MockMvcRequestBuilders, status().isOk(), @RestControllerAdvice, contentType(APPLICATION_JSON).

Independent GitHub snapshot · Automated classification · Original documentation governs

Skill 문서

GitHub

name: spring-mvc-testing description: "Boot 4+ replaced MockMvc assertions with MockMvcTester — incompatible API your training data gets wrong. Read before writing any @WebMvcTest. Triggers: @WebMvcTest, MockMvc, MockMvcTester, @RestController, jsonPath, @GetMapping, @PostMapping, @AutoConfigureMockMvc, MockMvcRequestBuilders, status().isOk(), @RestControllerAdvice, contentType(APPLICATION_JSON)." version: 0.1.0 license: Apache-2.0

Spring MVC Testing

Signals: @WebMvcTest, MockMvc, jsonPath, @AutoConfigureMockMvc, @RestController, MockMvcRequestBuilders, MockMvcResultMatchers, objectMapper

Tested With

  • Spring Boot 3.2+ / Spring Boot 4.x
  • Spring Framework 6.x / Spring Framework 7.x
  • Spring Security 6.x / 7.x (auto-configured in @WebMvcTest)
  • JUnit 5

Do NOT Use This Skill When

  • Testing authentication, authorization, CSRF, JWT, or OAuth2 specifically → use spring-security-testing
  • Testing reactive endpoints (WebFlux, WebClient, SSE) → use spring-webflux-testing
  • Testing JPA repositories or database persistence → use spring-jpa-testing
  • Testing WebSocket or STOMP messaging → use spring-websocket-testing
  • Writing pure unit tests without a Spring context → use spring-testing-fundamentals

When to Read References

SituationRead
Setting up @WebMvcTest, MockMvc configuration, static importsreferences/mvc-rest-testing-patterns.md
GET, POST, PUT, DELETE request patternsreferences/mvc-rest-testing-patterns.md
jsonPath assertions, response headers, multipart uploadsreferences/mvc-rest-testing-patterns.md
Testing @Valid bean validation, @RestControllerAdvice exception handlersreferences/mvc-rest-testing-patterns.md
Boot 4 RestTestClient migrationreferences/mvc-rest-testing-patterns.md
Anti-patterns and common mistakesreferences/mvc-rest-testing-patterns.md
저장한 Skills