[Bug] SpringBoot整合JUnit运行测试报错

十二月 17, 2020 9:16:43 下午 org.junit.vintage.engine.descriptor.RunnerTestDescriptor warnAboutUnfilterableRunner
警告: Runner org.junit.internal.runners.ErrorReportingRunner (used on class com.xyzhang.tacocloud.controller.HomeControllerTests) does not support filtering and will therefore be run completely.




org.junit.runners.model.InvalidTestClassError: Invalid test class 'com.xyzhang.tacocloud.controller.HomeControllerTests':
  1. No runnable methods

	at org.junit.runners.ParentRunner.validate(ParentRunner.java:525)
	at org.junit.runners.ParentRunner.<init>(ParentRunner.java:92)
	at org.junit.runners.BlockJUnit4ClassRunner.<init>(BlockJUnit4ClassRunner.java:74)
	at org.springframework.test.context.junit4.SpringJUnit4ClassRunner.<init>(SpringJUnit4ClassRunner.java:137)
	at org.springframework.test.context.junit4.SpringRunner.<init>(SpringRunner.java:49)
	at sun.reflect.NativeConstructorAccessorImpl.newInstance0(Native Method)
	at sun.reflect.NativeConstructorAccessorImpl.newInstance(NativeConstructorAccessorImpl.java:62)
	at sun.reflect.DelegatingConstructorAccessorImpl.newInstance(DelegatingConstructorAccessorImpl.java:45)
	at java.lang.reflect.Constructor.newInstance(Constructor.java:423)
	at org.junit.internal.builders.AnnotatedBuilder.buildRunn

你可能感兴趣的:(bug,junit,spring,java,spring,boot,后端)