Reputation: 2140
After adding TestNG tests to our Jenkins test job reports would no longer be produced. I removed the TestNG tests and dependencies and reports started to be produced again. How can I run both TestNG and JUnit tests with Maven-3 under Jenkins with reporting?
Upvotes: 1
Views: 658
Reputation: 14691
Is your pom configuring surefire as recommended here? (pom plugin example copied below) You should confirm that both test libraries are being run at the command line as well as from jenkins using the test goal.
<plugin>
<artifactId>maven-surefire-plugin</artifactId>
<version>${surefire.version}</version>
<dependencies>
<dependency>
<groupId>org.apache.maven.surefire</groupId>
<artifactId>surefire-junit47</artifactId>
<version>${surefire.version}</version>
</dependency>
<dependency>
<groupId>org.apache.maven.surefire</groupId>
<artifactId>surefire-testng</artifactId>
<version>${surefire.version}</version>
</dependency>
</dependencies>
</plugin>
Upvotes: 1