【Maven】maven项目 mvn clean install 或 build,报错:Failed to execute goal org.apache.maven.plugins:maven-surefire-plugin:2.12.4:test

maven项目执行编译或构建命令 ,mvn clean install  或  mvn build

报错: 

Failed to execute goal org.apache.maven.plugins:maven-surefire-plugin:2.12.4:test

报错如下:

 

解决方法:

添加:

       <plugin>
                <groupId>org.apache.maven.plugins</groupId>
                <artifactId>maven-surefire-plugin</artifactId>
                <version>2.12.4</version>
                <configuration>
                    <skipTests>true</skipTests>
                </configuration>
            </plugin>

在maven的pom.xml中

 

猜你喜欢

转载自www.cnblogs.com/sxdcgaq8080/p/12640793.html