mvn clean package:[ERROR] Failed to execute goal org.apache.maven.plugins:maven-surefire-plugin:2.12

时间:2023-03-09 02:39:05
mvn clean package:[ERROR] Failed to execute goal org.apache.maven.plugins:maven-surefire-plugin:2.12

原文地址:https://www.cnblogs.com/lxcy/p/8279899.html

事故现场:

mvn clean package:[ERROR] Failed to execute goal org.apache.maven.plugins:maven-surefire-plugin:2.12

解决办法:

一是命令行,

mvn clean package -Dmaven.test.skip=true

二是写入pom文件,

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