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

Test Result Trend chart not showing on Multibranch Pipeline branch if last build has no test results

      I'm not sure if this is a problem in xUnit or pipeline multibranch plugin. Please reassign this as required.

      We've got a Multibranch Pipeline project and we upload various test results using the xUnit plugin. It's somewhat like this:

      stage("Reachable stage") {
          if (some condition)
              return; // Skip all subsequent stages. This appears to cause the problem.
      }
      stage("Potentially failing or unreachable stage") {
          try
          {
              // This might fail and abort consequent stages.
          }
          finally
          {   // We still want all tests and artifacts that we can get, but we only care for artifacts whose unit tests were executed.
              xunit testTimeMargin: '2000', thresholdMode: 1, thresholds: [skipped(failureNewThreshold: '0', failureThreshold: '0', unstableNewThreshold: '0', unstableThreshold: '0'), failed(failureNewThreshold: '0', failureThreshold: '0', unstableNewThreshold: '0', unstableThreshold: '0')], tools: [xUnitDotNet(deleteOutputFiles: true, failIfNotNew: false, pattern: 'unittests.xml', skipNoTestFiles: false, stopProcessingIfError: true)]
              archiveArtifacts artifacts: '...', defaultExcludes: false
              xunit testTimeMargin: '2000', thresholdMode: 1, thresholds: [skipped(failureNewThreshold: '0', failureThreshold: '0', unstableNewThreshold: '0', unstableThreshold: '0'), failed(failureNewThreshold: '0', failureThreshold: '0', unstableNewThreshold: '0', unstableThreshold: '0')], tools: [xUnitDotNet(deleteOutputFiles: true, failIfNotNew: false, pattern: 'boxtests.xml', skipNoTestFiles: false, stopProcessingIfError: true)]
          }
      }
      stage("Potentially unreachable stage") {
      }
      
      

      The trend chart shows up when builds fail with or without tests or succeed with tests, but the chart disappears when the build skips stages which record the tests. To be entirely honest, I'm not sure what the current behavior is exactly (it's inconsistent).

      This should be fixed. As long as there are test results in any builds at all, they should be displayed regardless of test results in the latest build.

          [JENKINS-58960] Test Result Trend chart not showing on Multibranch Pipeline branch if last build has no test results

          Edgars Batna created issue -
          Edgars Batna made changes -
          Description Original: I'm not sure if this a problem in xUnit plugin. We've got a Multibranch Pipeline project and we upload various test results using the xUnit plugin. It's somewhat like this:
          {code:java}
          stage("Reachable stage") {
              if (some condition)
                  return; // Skip all subsequent stages. This appears to cause the problem.
          }
          stage("Potentially failing or unreachable stage") {
              try
              {
                  // This might fail and abort consequent stages.
              }
              finally
              { // We still want all tests and artifacts that we can get, but we only care for artifacts whose unit tests were executed.
                  xunit testTimeMargin: '2000', thresholdMode: 1, thresholds: [skipped(failureNewThreshold: '0', failureThreshold: '0', unstableNewThreshold: '0', unstableThreshold: '0'), failed(failureNewThreshold: '0', failureThreshold: '0', unstableNewThreshold: '0', unstableThreshold: '0')], tools: [xUnitDotNet(deleteOutputFiles: true, failIfNotNew: false, pattern: 'unittests.xml', skipNoTestFiles: false, stopProcessingIfError: true)]
                  archiveArtifacts artifacts: '...', defaultExcludes: false
                  xunit testTimeMargin: '2000', thresholdMode: 1, thresholds: [skipped(failureNewThreshold: '0', failureThreshold: '0', unstableNewThreshold: '0', unstableThreshold: '0'), failed(failureNewThreshold: '0', failureThreshold: '0', unstableNewThreshold: '0', unstableThreshold: '0')], tools: [xUnitDotNet(deleteOutputFiles: true, failIfNotNew: false, pattern: 'boxtests.xml', skipNoTestFiles: false, stopProcessingIfError: true)]
              }
          }
          stage("Potentially unreachable stage") {
          }

          {code}
          The trend chart shows up when builds fail with or without tests or succeed with tests, but the chart disappears when the build skips stages which record the tests.

          This should be fixed. As long as there are test results in any builds at all, they should be displayed regardless of test results in the latest build.
          New: I'm not sure if this is a problem in xUnit plugin. We've got a Multibranch Pipeline project and we upload various test results using the xUnit plugin. It's somewhat like this:
          {code:java}
          stage("Reachable stage") {
              if (some condition)
                  return; // Skip all subsequent stages. This appears to cause the problem.
          }
          stage("Potentially failing or unreachable stage") {
              try
              {
                  // This might fail and abort consequent stages.
              }
              finally
              { // We still want all tests and artifacts that we can get, but we only care for artifacts whose unit tests were executed.
                  xunit testTimeMargin: '2000', thresholdMode: 1, thresholds: [skipped(failureNewThreshold: '0', failureThreshold: '0', unstableNewThreshold: '0', unstableThreshold: '0'), failed(failureNewThreshold: '0', failureThreshold: '0', unstableNewThreshold: '0', unstableThreshold: '0')], tools: [xUnitDotNet(deleteOutputFiles: true, failIfNotNew: false, pattern: 'unittests.xml', skipNoTestFiles: false, stopProcessingIfError: true)]
                  archiveArtifacts artifacts: '...', defaultExcludes: false
                  xunit testTimeMargin: '2000', thresholdMode: 1, thresholds: [skipped(failureNewThreshold: '0', failureThreshold: '0', unstableNewThreshold: '0', unstableThreshold: '0'), failed(failureNewThreshold: '0', failureThreshold: '0', unstableNewThreshold: '0', unstableThreshold: '0')], tools: [xUnitDotNet(deleteOutputFiles: true, failIfNotNew: false, pattern: 'boxtests.xml', skipNoTestFiles: false, stopProcessingIfError: true)]
              }
          }
          stage("Potentially unreachable stage") {
          }

          {code}
          The trend chart shows up when builds fail with or without tests or succeed with tests, but the chart disappears when the build skips stages which record the tests.

          This should be fixed. As long as there are test results in any builds at all, they should be displayed regardless of test results in the latest build.
          Edgars Batna made changes -
          Description Original: I'm not sure if this is a problem in xUnit plugin. We've got a Multibranch Pipeline project and we upload various test results using the xUnit plugin. It's somewhat like this:
          {code:java}
          stage("Reachable stage") {
              if (some condition)
                  return; // Skip all subsequent stages. This appears to cause the problem.
          }
          stage("Potentially failing or unreachable stage") {
              try
              {
                  // This might fail and abort consequent stages.
              }
              finally
              { // We still want all tests and artifacts that we can get, but we only care for artifacts whose unit tests were executed.
                  xunit testTimeMargin: '2000', thresholdMode: 1, thresholds: [skipped(failureNewThreshold: '0', failureThreshold: '0', unstableNewThreshold: '0', unstableThreshold: '0'), failed(failureNewThreshold: '0', failureThreshold: '0', unstableNewThreshold: '0', unstableThreshold: '0')], tools: [xUnitDotNet(deleteOutputFiles: true, failIfNotNew: false, pattern: 'unittests.xml', skipNoTestFiles: false, stopProcessingIfError: true)]
                  archiveArtifacts artifacts: '...', defaultExcludes: false
                  xunit testTimeMargin: '2000', thresholdMode: 1, thresholds: [skipped(failureNewThreshold: '0', failureThreshold: '0', unstableNewThreshold: '0', unstableThreshold: '0'), failed(failureNewThreshold: '0', failureThreshold: '0', unstableNewThreshold: '0', unstableThreshold: '0')], tools: [xUnitDotNet(deleteOutputFiles: true, failIfNotNew: false, pattern: 'boxtests.xml', skipNoTestFiles: false, stopProcessingIfError: true)]
              }
          }
          stage("Potentially unreachable stage") {
          }

          {code}
          The trend chart shows up when builds fail with or without tests or succeed with tests, but the chart disappears when the build skips stages which record the tests.

          This should be fixed. As long as there are test results in any builds at all, they should be displayed regardless of test results in the latest build.
          New: I'm not sure if this is a problem in xUnit plugin. Please reassign this as required.

          We've got a Multibranch Pipeline project and we upload various test results using the xUnit plugin. It's somewhat like this:
          {code:java}
          stage("Reachable stage") {
              if (some condition)
                  return; // Skip all subsequent stages. This appears to cause the problem.
          }
          stage("Potentially failing or unreachable stage") {
              try
              {
                  // This might fail and abort consequent stages.
              }
              finally
              { // We still want all tests and artifacts that we can get, but we only care for artifacts whose unit tests were executed.
                  xunit testTimeMargin: '2000', thresholdMode: 1, thresholds: [skipped(failureNewThreshold: '0', failureThreshold: '0', unstableNewThreshold: '0', unstableThreshold: '0'), failed(failureNewThreshold: '0', failureThreshold: '0', unstableNewThreshold: '0', unstableThreshold: '0')], tools: [xUnitDotNet(deleteOutputFiles: true, failIfNotNew: false, pattern: 'unittests.xml', skipNoTestFiles: false, stopProcessingIfError: true)]
                  archiveArtifacts artifacts: '...', defaultExcludes: false
                  xunit testTimeMargin: '2000', thresholdMode: 1, thresholds: [skipped(failureNewThreshold: '0', failureThreshold: '0', unstableNewThreshold: '0', unstableThreshold: '0'), failed(failureNewThreshold: '0', failureThreshold: '0', unstableNewThreshold: '0', unstableThreshold: '0')], tools: [xUnitDotNet(deleteOutputFiles: true, failIfNotNew: false, pattern: 'boxtests.xml', skipNoTestFiles: false, stopProcessingIfError: true)]
              }
          }
          stage("Potentially unreachable stage") {
          }

          {code}
          The trend chart shows up when builds fail with or without tests or succeed with tests, but the chart disappears when the build skips stages which record the tests.

          This should be fixed. As long as there are test results in any builds at all, they should be displayed regardless of test results in the latest build.
          Edgars Batna made changes -
          Description Original: I'm not sure if this is a problem in xUnit plugin. Please reassign this as required.

          We've got a Multibranch Pipeline project and we upload various test results using the xUnit plugin. It's somewhat like this:
          {code:java}
          stage("Reachable stage") {
              if (some condition)
                  return; // Skip all subsequent stages. This appears to cause the problem.
          }
          stage("Potentially failing or unreachable stage") {
              try
              {
                  // This might fail and abort consequent stages.
              }
              finally
              { // We still want all tests and artifacts that we can get, but we only care for artifacts whose unit tests were executed.
                  xunit testTimeMargin: '2000', thresholdMode: 1, thresholds: [skipped(failureNewThreshold: '0', failureThreshold: '0', unstableNewThreshold: '0', unstableThreshold: '0'), failed(failureNewThreshold: '0', failureThreshold: '0', unstableNewThreshold: '0', unstableThreshold: '0')], tools: [xUnitDotNet(deleteOutputFiles: true, failIfNotNew: false, pattern: 'unittests.xml', skipNoTestFiles: false, stopProcessingIfError: true)]
                  archiveArtifacts artifacts: '...', defaultExcludes: false
                  xunit testTimeMargin: '2000', thresholdMode: 1, thresholds: [skipped(failureNewThreshold: '0', failureThreshold: '0', unstableNewThreshold: '0', unstableThreshold: '0'), failed(failureNewThreshold: '0', failureThreshold: '0', unstableNewThreshold: '0', unstableThreshold: '0')], tools: [xUnitDotNet(deleteOutputFiles: true, failIfNotNew: false, pattern: 'boxtests.xml', skipNoTestFiles: false, stopProcessingIfError: true)]
              }
          }
          stage("Potentially unreachable stage") {
          }

          {code}
          The trend chart shows up when builds fail with or without tests or succeed with tests, but the chart disappears when the build skips stages which record the tests.

          This should be fixed. As long as there are test results in any builds at all, they should be displayed regardless of test results in the latest build.
          New: I'm not sure if this is a problem in xUnit plugin. Please reassign this as required.

          We've got a Multibranch Pipeline project and we upload various test results using the xUnit plugin. It's somewhat like this:
          {code:java}
          stage("Reachable stage") {
              if (some condition)
                  return; // Skip all subsequent stages. This appears to cause the problem.
          }
          stage("Potentially failing or unreachable stage") {
              try
              {
                  // This might fail and abort consequent stages.
              }
              finally
              { // We still want all tests and artifacts that we can get, but we only care for artifacts whose unit tests were executed.
                  xunit testTimeMargin: '2000', thresholdMode: 1, thresholds: [skipped(failureNewThreshold: '0', failureThreshold: '0', unstableNewThreshold: '0', unstableThreshold: '0'), failed(failureNewThreshold: '0', failureThreshold: '0', unstableNewThreshold: '0', unstableThreshold: '0')], tools: [xUnitDotNet(deleteOutputFiles: true, failIfNotNew: false, pattern: 'unittests.xml', skipNoTestFiles: false, stopProcessingIfError: true)]
                  archiveArtifacts artifacts: '...', defaultExcludes: false
                  xunit testTimeMargin: '2000', thresholdMode: 1, thresholds: [skipped(failureNewThreshold: '0', failureThreshold: '0', unstableNewThreshold: '0', unstableThreshold: '0'), failed(failureNewThreshold: '0', failureThreshold: '0', unstableNewThreshold: '0', unstableThreshold: '0')], tools: [xUnitDotNet(deleteOutputFiles: true, failIfNotNew: false, pattern: 'boxtests.xml', skipNoTestFiles: false, stopProcessingIfError: true)]
              }
          }
          stage("Potentially unreachable stage") {
          }

          {code}
          The trend chart shows up when builds fail with or without tests or succeed with tests, but the chart disappears when the build skips stages which record the tests. To be entirely honest, I'm not sure what the current behavior is exactly (it's inconsistent).

          This should be fixed. As long as there are test results in any builds at all, they should be displayed regardless of test results in the latest build.
          Edgars Batna made changes -
          Component/s New: multi-branch-project-plugin (not Pipeline) [ 21127 ]
          Edgars Batna made changes -
          Description Original: I'm not sure if this is a problem in xUnit plugin. Please reassign this as required.

          We've got a Multibranch Pipeline project and we upload various test results using the xUnit plugin. It's somewhat like this:
          {code:java}
          stage("Reachable stage") {
              if (some condition)
                  return; // Skip all subsequent stages. This appears to cause the problem.
          }
          stage("Potentially failing or unreachable stage") {
              try
              {
                  // This might fail and abort consequent stages.
              }
              finally
              { // We still want all tests and artifacts that we can get, but we only care for artifacts whose unit tests were executed.
                  xunit testTimeMargin: '2000', thresholdMode: 1, thresholds: [skipped(failureNewThreshold: '0', failureThreshold: '0', unstableNewThreshold: '0', unstableThreshold: '0'), failed(failureNewThreshold: '0', failureThreshold: '0', unstableNewThreshold: '0', unstableThreshold: '0')], tools: [xUnitDotNet(deleteOutputFiles: true, failIfNotNew: false, pattern: 'unittests.xml', skipNoTestFiles: false, stopProcessingIfError: true)]
                  archiveArtifacts artifacts: '...', defaultExcludes: false
                  xunit testTimeMargin: '2000', thresholdMode: 1, thresholds: [skipped(failureNewThreshold: '0', failureThreshold: '0', unstableNewThreshold: '0', unstableThreshold: '0'), failed(failureNewThreshold: '0', failureThreshold: '0', unstableNewThreshold: '0', unstableThreshold: '0')], tools: [xUnitDotNet(deleteOutputFiles: true, failIfNotNew: false, pattern: 'boxtests.xml', skipNoTestFiles: false, stopProcessingIfError: true)]
              }
          }
          stage("Potentially unreachable stage") {
          }

          {code}
          The trend chart shows up when builds fail with or without tests or succeed with tests, but the chart disappears when the build skips stages which record the tests. To be entirely honest, I'm not sure what the current behavior is exactly (it's inconsistent).

          This should be fixed. As long as there are test results in any builds at all, they should be displayed regardless of test results in the latest build.
          New: I'm not sure if this is a problem in xUnit or pipeline multibranch plugin. Please reassign this as required.

          We've got a Multibranch Pipeline project and we upload various test results using the xUnit plugin. It's somewhat like this:
          {code:java}
          stage("Reachable stage") {
              if (some condition)
                  return; // Skip all subsequent stages. This appears to cause the problem.
          }
          stage("Potentially failing or unreachable stage") {
              try
              {
                  // This might fail and abort consequent stages.
              }
              finally
              { // We still want all tests and artifacts that we can get, but we only care for artifacts whose unit tests were executed.
                  xunit testTimeMargin: '2000', thresholdMode: 1, thresholds: [skipped(failureNewThreshold: '0', failureThreshold: '0', unstableNewThreshold: '0', unstableThreshold: '0'), failed(failureNewThreshold: '0', failureThreshold: '0', unstableNewThreshold: '0', unstableThreshold: '0')], tools: [xUnitDotNet(deleteOutputFiles: true, failIfNotNew: false, pattern: 'unittests.xml', skipNoTestFiles: false, stopProcessingIfError: true)]
                  archiveArtifacts artifacts: '...', defaultExcludes: false
                  xunit testTimeMargin: '2000', thresholdMode: 1, thresholds: [skipped(failureNewThreshold: '0', failureThreshold: '0', unstableNewThreshold: '0', unstableThreshold: '0'), failed(failureNewThreshold: '0', failureThreshold: '0', unstableNewThreshold: '0', unstableThreshold: '0')], tools: [xUnitDotNet(deleteOutputFiles: true, failIfNotNew: false, pattern: 'boxtests.xml', skipNoTestFiles: false, stopProcessingIfError: true)]
              }
          }
          stage("Potentially unreachable stage") {
          }

          {code}
          The trend chart shows up when builds fail with or without tests or succeed with tests, but the chart disappears when the build skips stages which record the tests. To be entirely honest, I'm not sure what the current behavior is exactly (it's inconsistent).

          This should be fixed. As long as there are test results in any builds at all, they should be displayed regardless of test results in the latest build.
          Nikolas Falco made changes -
          Component/s New: junit-plugin [ 15499 ]
          Component/s Original: xunit-plugin [ 15636 ]
          Nikolas Falco made changes -
          Assignee Original: Nikolas Falco [ nfalco ] New: Matthew DeTullio [ mjdetullio ]
          Matthew DeTullio made changes -
          Component/s New: core [ 15593 ]
          Component/s Original: multi-branch-project-plugin (not Pipeline) [ 21127 ]
          Matthew DeTullio made changes -
          Assignee Original: Matthew DeTullio [ mjdetullio ]

            Unassigned Unassigned
            gl1koz3 Edgars Batna
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

              Created:
              Updated: