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

Add way to easily test currentBuild result is better/worse than some value (isBetterOrEqualTo)

XMLWordPrintable

      Currently currentBuild.result returns a string. This makes testing whether a result is better/worse than some status. This functionality is present in hudson.model.Result as isBetterOrEqualTo and isWorseOrEqualTo

      Suggest one of two solutions:
      1. Wiring this through as currentBuild.resultIsBetterOrEqualTo(String) and currentBuild.resultIsWorseOrEqualTo(String).
      2. Add a currentBuild.resultValue property that returns the raw hudson.model.Result value from which someone could run isBetterOrEqualTo

            abayer Andrew Bayer
            bitwiseman Liam Newman
            Votes:
            1 Vote for this issue
            Watchers:
            4 Start watching this issue

              Created:
              Updated:
              Resolved: