springboot的测试启动失败
温馨提示:
本文最后更新于 2025年09月07日,已超过 278 天没有更新。若文章内的图片失效(无法正常加载),请留言反馈或直接联系我。
出现问题 java.lang.IllegalStateException: Unable to find a @SpringBootConfiguration, you need to use @ContextConfiguration or @SpringBootTest(classes=...) with your test
解决方法:指定具体的 classes
@SpringBootTest (classes = ProductMainApplication.class)
正文到此结束
- 本文标签: SpringCloud
- 本文链接: http://119.91.109.247:8443//article/131
- 版权声明: 本文由张亚东原创发布,转载请遵循《署名-非商业性使用-相同方式共享 4.0 国际 (CC BY-NC-SA 4.0)》许可协议授权