Mac+IDEA+maven+java+testng.xml
本地执行maven test testng.xml成功
mac搭建Jenkins并配置好环境后,Jenkins 构建maven项目报错
<build>
<plugins>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-surefire-plugin</artifactId>
<version>3.0.0-M5</version>
<configuration>
<suiteXmlFiles>
<suiteXmlFile>testng.xml</suiteXmlFile>
</suiteXmlFiles>
<forkMode>once</forkMode>
<argLine>-Dfile.encoding=UTF-8</argLine>
<systemProperties>
<property>
<name>net.sourceforge.cobertura.datafile</name>
<value>target/cobertura/cobertura.ser</value>
</property>
</systemProperties>
</configuration>
</plugin>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-compiler-plugin</artifactId>
<version>3.1</version>
<configuration>
<encoding>UTF-8</encoding>
<verbose>true</verbose>
<fork>true</fork>
<executable>/Library/Java/JavaVirtualMachines/jdk1.8.0_291.jdk/Contents/Home/bin/javac</executable>
</configuration>
</plugin>
</plugins>
</build>
看着是maven jar包的问题,但是检查了一下Jenkins系统设置和项目都做了maven相关的配置
你用jdgui 工具反编译一下这个jar包看看有没有