Uploaded image for project: 'Jenkins'
  1. Jenkins
  2. JENKINS-10736

No support for UnitTest XML reporting per sub job when using matrix projects

    • Icon: Bug Bug
    • Resolution: Duplicate
    • Icon: Major Major
    • xunit-plugin
    • None
    • Jenkins v1.426
      xUnit Plugin v1.20

      Hi there,

      I've got a matrix project which builds some unit test executables and then the PostBuild Step in Visual Studio actually runs them. The UnitTest executables output a UnitTest-1.4 XML results file. To hook this into Jenkins I use the "Publish testing tools result report" option in the "Post-build Action" part of my project setup.

      The matrix project has 2 sub jobs - Debug and Release. In my project setup I have 2 patterns configured:

      1) Debug build
      tfields/Live/Engine/Tests/UnitTests/Core/LOD/UnitTestsLODResultsWin32D.xml

      2) Release build
      tfields/Live/Engine/Tests/UnitTests/Core/LOD/UnitTestsLODResultsWin32.xml

      The first (Debug) sub-job builds, runs then outputs:

      16:27:56  Total time: 1 minute 42 seconds
      16:27:56  [xUnit] [INFO] - Starting to record.
      16:27:56  [xUnit] [INFO] - Processing UnitTest-1.4 (default)
      16:27:56  [xUnit] [INFO] - [UnitTest-1.4 (default)] - 1 test report file(s) were found with the pattern 'tfields/Live/Engine/Tests/UnitTests/Core/LOD/UnitTestsLODResultsWin32D.xml' relative to 'C:\JCI\workspace\UnitTest_Core_LOD\COMPILER\CL\CONFIG\Debug\PLATFORM\Win32' for the testing framework 'UnitTest-1.4 (default)'.
      16:27:56  [xUnit] [INFO] - Processing UnitTest-1.4 (default)
      16:27:56  [xUnit] [WARNING] - Can't create the path C:\JCI\workspace\UnitTest_Core_LOD\COMPILER\CL\CONFIG\Debug\PLATFORM\Win32\generatedJUnitFiles. Maybe the directory already exists.
      16:27:56  [xUnit] [INFO] - [UnitTest-1.4 (default)] - No test report file(s) were found with the pattern 'tfields/Live/Engine/Tests/UnitTests/Core/LOD/UnitTestsLODResultsWin32.xml' relative to 'C:\JCI\workspace\UnitTest_Core_LOD\COMPILER\CL\CONFIG\Debug\PLATFORM\Win32' for the testing framework 'UnitTest-1.4 (default)'.  Did you enter a pattern relative to the correct directory?  Did you generate the result report(s) for 'UnitTest-1.4 (default)'?
      16:27:56  [xUnit] [ERROR] - No test reports found for the metric 'UnitTest-1.4 (default)' with the resolved pattern 'tfields/Live/Engine/Tests/UnitTests/Core/LOD/UnitTestsLODResultsWin32.xml'. Configuration error?.
      16:27:56  [xUnit] [INFO] - Stopping recording.
      

      As you can see it even though it's doing the "Debug" build first, it's already looking for the Release version of the XML results even though the build hasn't happened yet.

      Can the plugin be updated to support XML results per subjob? Or is there another way to achieve what I'm trying to do?

      Regards,
      Tom.

          [JENKINS-10736] No support for UnitTest XML reporting per sub job when using matrix projects

          Thomas Fields added a comment -

          Any comment gbois? Am I going about this the wrong way or can be the plugin be updated? Many thanks Tom

          Thomas Fields added a comment - Any comment gbois? Am I going about this the wrong way or can be the plugin be updated? Many thanks Tom

          Thomas Fields added a comment -

          Any update on this issue?

          Thomas Fields added a comment - Any update on this issue?

          Could you attach your job configuration file (config.xml)?
          I'll try to reproduce the problem and fix the plugin.
          Thanks

          Gregory Boissinot added a comment - Could you attach your job configuration file (config.xml)? I'll try to reproduce the problem and fix the plugin. Thanks

          Thomas Fields added a comment -

          Sorry for the delay gbois. I've attached my config.xml file. As you can see it's a matrix build with each element creating a different xml results file.

          Cheers,
          Tom.

          Thomas Fields added a comment - Sorry for the delay gbois. I've attached my config.xml file. As you can see it's a matrix build with each element creating a different xml results file. Cheers, Tom.

          Thomas Fields added a comment -

          Has any progress been made on this issue?

          Tom

          Thomas Fields added a comment - Has any progress been made on this issue? Tom

          Thomas Fields added a comment -

          Sorry to be pushy but is there any chance this could be fixed?

          Regards,
          Tom.

          Thomas Fields added a comment - Sorry to be pushy but is there any chance this could be fixed? Regards, Tom.

          Thomas Fields added a comment -

          This is still marked as in progress. Is it actually in progress?

          Thomas Fields added a comment - This is still marked as in progress. Is it actually in progress?

          I have not yet had time to look at it.

          Gregory Boissinot added a comment - I have not yet had time to look at it.

          Ireneusz Makowski added a comment - - edited

          Have you look at it? I have the same issue when NUnit report is selected as source

          Ireneusz Makowski added a comment - - edited Have you look at it? I have the same issue when NUnit report is selected as source

          Thomas Fields added a comment -

          Are we any closer to getting this fixed?

          Thomas Fields added a comment - Are we any closer to getting this fixed?

            gbois Gregory Boissinot
            tfields Thomas Fields
            Votes:
            1 Vote for this issue
            Watchers:
            3 Start watching this issue

              Created:
              Updated:
              Resolved: