spring2.5不支持junit 4.5以上版本
使用spring 2.5,以前用junit 4.4,这次在maven中将依赖类库写为4.7版本,结果看到类似这样的报错: org.apache.maven.surefire.booter.SurefireExecutionException: org/junit/Assume$AssumptionViolatedException; nested exception is java.lang.NoClassDefFoundError: org/junit/Assume$AssumptionViolatedException java.lang.NoClassDefFoundError: org/junit/Assume$AssumptionViolatedException at org.springframework.test.context.junit4.SpringMethodRoadie.runTestMethod(SpringMethodRoadie.java:240) 查了一下原因,见: http://jira.springframework.org/browse/SPR-5145 这个问题在最新的spring 3.0版本中得到解决。 但是我们依然用2.5.6版本的spring,因此将junit改回为4.4版本。问题解决。 发送文章为PDF