在pom.xml中添加一下代码:

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

如下:

maven项目打包跳过单元测试-LMLPHP

05-19 16:04