You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@maven.apache.org by "Elias Balasis (JIRA)" <ji...@apache.org> on 2017/07/07 14:26:00 UTC

[jira] [Comment Edited] (SUREFIRE-1346) surefire-reports overwrite each other when using reuseForks=false

    [ https://issues.apache.org/jira/browse/SUREFIRE-1346?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16078153#comment-16078153 ] 

Elias Balasis edited comment on SUREFIRE-1346 at 7/7/17 2:25 PM:
-----------------------------------------------------------------

Following a long discussion under SUREFIRE-875 and beyond which [~tibor17] is familiar with,

when Surefire calls multiple executions of the underlying test framework (TestNG in this case), with or without forks, it has to do so under a dedicated sub-folder for each execution so that previous test output will not be overwritten.

The underlying test framework (mainly TestNG in this case) generates output in folder Surefire runs it under, Surefire controlled.

I am hoping for
target/surefire-reports/exec1/...
target/surefire-reports/exec2/...
etc.

and similarly for "failsafe" plugin

However, for a single test execution scenario, no sub-folder is required.

The above is expected to hold true for any underlying test framework (e.g. JUnit)

Any thoughts?



was (Author: eliasbalasis):
Following a long discussion under SUREFIRE-875 ([~tibor17] is familiar with this),

when Surefire calls multiple executions of the underlying test framework (TestNG in this case), with or without forks, it has to do so under a dedicated sub-folder for each execution so that previous test output will not be overwritten.

The underlying test framework (mainly TestNG in this case) generates output in folder Surefire runs it under, Surefire controlled.

I am hoping for
target/surefire-reports/exec1/...
target/surefire-reports/exec2/...
etc.

and similarly for "failsafe" plugin

However, for a single test execution scenario, no sub-folder is required.

The above is expected to hold true for any underlying test framework (e.g. JUnit)

Any thoughts?


> surefire-reports overwrite each other when using reuseForks=false
> -----------------------------------------------------------------
>
>                 Key: SUREFIRE-1346
>                 URL: https://issues.apache.org/jira/browse/SUREFIRE-1346
>             Project: Maven Surefire
>          Issue Type: Bug
>          Components: process forking, TestNG support
>    Affects Versions: 2.19.1
>            Reporter: Antoine Tran
>
> In a Maven project with the setting "<reuseForks>false</reuseForks>" and TestNg, the file testng-result.xml gets overwritten by the last test.
> I somehow understand why it is difficult to avoid this by design of fork, but a workaround solution, as suggested by SUREFIRE-1018 or SUREFIRE-446, is to use the individual TEST-[className].xml files.
> However, if I use a Jenkins plugin like testng, I cannot make him ingest these files, as they do not have the same structure as testng-result.xml. This is a bug of testng, rather than the Jenkins plugin testng. Couldn't we make testng-result-[className].xml, for each test, with the testng-result.xml structure? Otherwise, the Jenkins plugin https://wiki.jenkins-ci.org/display/JENKINS/testng-plugin is completely not usable.
> Thank you.



--
This message was sent by Atlassian JIRA
(v6.4.14#64029)