Springboot项目测试类,报错Unable to find a @SpringBootConfiguration, you need to use @ContextConfigura

解决: 注解加需要测试的class

@SpringBootTest(classes = StudentInfoServiceImpl.class)
@RunWith(SpringRunner.class)
posted @ 2020-06-04 13:38  wqkeep  阅读(7457)  评论(0编辑  收藏  举报