springboot启动类报错
java.lang.IllegalStateException: Unable to find a @SpringBootConfiguration, you need to use
@ContextConfiguration or @SpringBootTest(classes=...) with your test at org.springframework.util.Assert.state(Assert.java:76) at org.springframework.boot.test.context.SpringBootTestContextBootstrapper.g
etOrFindConfigurationClasses(SpringBootTestContextBoo
注意测试单元路径要与主启动类包路径要一直
不然你就要指定你的主启动类在哪 @SpringBootTest(classes=...)
本文来自博客园,作者:余生请多指教ANT,转载请注明原文链接:https://www.cnblogs.com/wangbiaohistory/p/17003481.html

浙公网安备 33010602011771号