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

Percentage Threshold Is Broken for 100%

XMLWordPrintable

    • Icon: Bug Bug
    • Resolution: Unresolved
    • Icon: Minor Minor
    • testng-plugin
    • None

      I was wondering why 

      https://github.com/jenkinsci/testng-plugin-plugin/commit/0da7b0d663dc8d69df85246e3fdacffa37db9f7e#diff-b1996c7392724f8e7f9b91c7ae3c4974R153 was merged in in favor of using > rather than >=.

      More specifically, if I were to set the failure threshold to be 100% and 100% of my tests fail, then https://github.com/jenkinsci/testng-plugin-plugin/blob/master/src/main/java/hudson/plugins/testng/Publisher.java#L251 would never happen.

      I believe there are two ways to fix this: 

      1) add an if for this edge case (I don't like this option)

      2) change the checks back to >= since I would think you would alert when a threshold is hit rather than just when it is exceeded.

            Unassigned Unassigned
            ahuang Alvin Huang
            Votes:
            1 Vote for this issue
            Watchers:
            2 Start watching this issue

              Created:
              Updated: