在Spring Boot中打包时跳过单元测试其实很简单,只要在pom文件的properties
标签中配置<skipTests>true</skipTests>
即可,示例:
<properties>
<project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
<project.reporting.outputEncoding>UTF-8</project.reporting.outputEncoding>
<java.version>1.8</java.version>
<skipTests>true</skipTests>
</properties>