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

    XMLWordPrintable

    Details

    • Similar Issues:

      Description

      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.

        Attachments

          Activity

          gl1koz3 Edgars Batna created issue -
          gl1koz3 Edgars Batna made changes -
          Field Original Value New Value
          Description 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.
          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.
          gl1koz3 Edgars Batna made changes -
          Description 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.
          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.
          gl1koz3 Edgars Batna made changes -
          Description 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.
          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.
          gl1koz3 Edgars Batna made changes -
          Component/s multi-branch-project-plugin (not Pipeline) [ 21127 ]
          gl1koz3 Edgars Batna made changes -
          Description 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.
          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.
          nfalco Nikolas Falco made changes -
          Component/s junit-plugin [ 15499 ]
          Component/s xunit-plugin [ 15636 ]
          Hide
          nfalco Nikolas Falco added a comment - - edited

          The behavior of trend result is part of junit plugin.

          Show
          nfalco Nikolas Falco added a comment - - edited The behavior of trend result is part of junit plugin.
          nfalco Nikolas Falco made changes -
          Assignee Nikolas Falco [ nfalco ] Matthew DeTullio [ mjdetullio ]

            People

            Assignee:
            mjdetullio Matthew DeTullio
            Reporter:
            gl1koz3 Edgars Batna
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

              Dates

              Created:
              Updated: