Maven2 Surefire Reports problem

I noticed that I am not getting reports for a group of testng unit tests. It appears that the SurefireReportProcessorImpl is attempting to use the name of the file with the group appended to it:

DEBUG - re.SurefireReportProcessorImpl - file does not exist: D:\buildtools\TeamCity\buildAgent\work\Server\663a964b96a93d35\server\server-tests\target\surefire-reports\TEST-com.g1.dcg.server.fileserver.TestFileServerManager (of integration).xml

I am running the 'integration' group of my unit tests. This group name is getting appended to the test report name and thus is not found by the TeamCity build agent. Has this been addressed in 3.0 release? Thanks!

Rick Cole

3 comments

Hello Rick,

No. This hasn't been addressed in 3.0.

Would you please provide me with more details.

How do you run your test group?
How are the tests configured (annotations, extarnal xml)?
Which versions of Surefire plugin and TestNG are you using?

This would be very helpful if you send me the corresponding fragments of
pom.xml and test classes.

Thank you.

I noticed that I am not getting reports for a group of testng unit
tests. It appears that the SurefireReportProcessorImpl is attempting
to use the name of the file with the group appended to it:

DEBUG - re.SurefireReportProcessorImpl -
file does not exist:
D:\buildtools\TeamCity\buildAgent\work\Server\663a964b96a93d35\server\
server-tests\target\surefire-reports\TEST-com.g1.dcg.server.fileserver
.TestFileServerManager (of integration).xml

I am running the 'integration' group of my unit tests. This group name
is getting appended to the test report name and thus is not found by
the TeamCity build agent. Has this been addressed in 3.0 release?
Thanks!

Rick Cole

--
Sergey Anchipolevsky
Software Developer
JetBrains, Inc
http://www.jetbrains.com
"Develop with pleasure!"


0

Sergey:

Here is the pom.xml fragment:

org.apache.maven.plugins maven-surefire-plugin 2.4-collab-SNAPSHOT server.test.dir target/container.dir/server integration ]]>

The groups are being declared in the testng test using annotations:

@Test(groups={"integration"})
public class TestEventManager
{
...
}

Here is what is being displayed in the build log for each test:

: Running com.g1.dcg.server.datasource.TestDataSourceManager (of integration)
: Surefire report not found for any of:
: Tests run: 10, Failures: 0, Errors: 0, Skipped: 0, Time elapsed: 2.874 sec

It looks like the 'of integration' text is being appended to the end of the test name when searching for the surefire report.

Let me know if there is anything else I can provide.
Thanks!

Rick

0

Hello Rick,

That's quite enough. Thank you.
The fix will be included into 3.0.1.

Thank you for reporting.

Sergey:

Here is the pom.xml fragment:

<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-surefire-plugin</artifactId>
<version>2.4-collab-SNAPSHOT</version>
<configuration>
<systemProperties>
<property>
<name>server.test.dir</name>
<value>target/container.dir/server</value>
</property>
</systemProperties>
<groups>integration</groups>
</configuration>
</plugin>
The groups are being declared in the testng test using annotations:

@Test(groups={"integration"})
public class TestEventManager
{
...
}
Here is what is being displayed in the build log for each test:

: Running com.g1.dcg.server.datasource.TestDataSourceManager
(of integration)

: Surefire report not found for any of:


: Tests run: 10, Failures: 0, Errors: 0, Skipped: 0, Time
elapsed: 2.874 sec

It looks like the 'of integration' text is being appended to the end
of the test name when searching for the surefire report.

Let me know if there is anything else I can provide. Thanks!

Rick

--
Sergey Anchipolevsky
Software Developer
JetBrains, Inc
http://www.jetbrains.com
"Develop with pleasure!"


0

Please sign in to leave a comment.