解决maven项目里的灰色jar包 maven检出的项目,运行时报错,检查发现有的jar包是灰色的 其实是因为pom.xml里面的配置问题 <dependency> <groupId>junit</groupId> <artifactId>junit</artifactId> <version>4.11</version> <scope>test</scope> </dependency> 把test删掉或者注掉就能解决这个问题。