Skip to content

Breaking API changes for TestReport in Jenkins 2 #184

Description

@tom-smalls

Disclaimer: I've only noticed this in Jenkins version 2.7.3

I noticed I was getting 0 back for the TestReport.getTotalCount() yesterday after looking into the upgrade process from a Jenkins 1.6.X server to Jenkins 2. After looking at the JSON API for test report on Jenkins 2, I noticed that there is no totalCount attribute anymore, with the following available:

"empty" : false,
"failCount" : 0,
"passCount" : 458,
"skipCount" : 2,

I'm not sure what the best approach would be to "fix" this whilst maintaining backward compatibility. Potentially looking for (and summing) failCount, passCount, and skipCount if totalCount returns 0 in the library? As far as I'm aware, passCount is new as well. Alternatively, doing something with the empty flag.

What are your thoughts?

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

      Milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions