A developer needs to write a test for a Spring MVC `@RestController` that focuses exclusively on the web layer. The test should verify request mappings, JSON serialization/deserialization, and exception handling without loading the service or repository layers. Which annotation is most suitable for this purpose?
-
A
`@SpringBootTest`
-
B
`@WebMvcTest(MyController.class)`
-
C
`@DataJpaTest`
-
D
`@ExtendWith(MockitoExtension.class)`