spring 配置junit 启动时出现 ClassNotFound警告

spring 配置junit 启动时出现 ClassNotFound警告:
 
警告: Failed to classload type while reading annotation metadata. This is a non-fatal error, but certain annotation metadata may be unavailable. java.lang.ClassNotFoundException: org.testng.annotations.BeforeTest
 
 
解决方法:
 
将eclipse自带的junit和org.hamcrest.core.jar复制到项目的WEB-INF/lib中,在buildpath中把eclipse自带的junit库移除掉即可
posted @ 2013-03-18 19:36  yanzhenxing  阅读(1296)  评论(0编辑  收藏  举报