Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Checks API integration #180

Merged
merged 12 commits into from
Oct 14, 2020
Merged

Checks API integration #180

merged 12 commits into from
Oct 14, 2020

Conversation

timja
Copy link
Member

@timja timja commented Oct 10, 2020

Fixes #160

TODO:

  • Add to jelly files
  • Tests
  • Documentation
  • Test freestyle builds
  • Use display url API for test report

Example reports can be found in:

https://github.com/timja-org/junit-attachments-test/pulls

A good one is:
https://github.com/timja-org/junit-attachments-test/pull/4/checks?check_run_id=1235203424

and:
timja-org/junit-attachments-test#5

System.out.println(text);
ChecksOutput output = new ChecksOutput.ChecksOutputBuilder()
.withTitle(extractChecksTitle())
.withSummary("<sub>Send us [feedback](https://github.com/jenkinsci/junit-plugin/issues)")
Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I was wondering about maybe having a Feedback <- survey, and a bug report link, thoughts?

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Whatever works best for you. Just GitHub issues might be enough for developers, but a survey is better for common users

Copy link
Member

@oleg-nenashev oleg-nenashev left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks very promising 👍 . I have not tested the report generation, but I do not see anything wrong in the code. Looking forward to try it out

System.out.println(text);
ChecksOutput output = new ChecksOutput.ChecksOutputBuilder()
.withTitle(extractChecksTitle())
.withSummary("<sub>Send us [feedback](https://github.com/jenkinsci/junit-plugin/issues)")
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Whatever works best for you. Just GitHub issues might be enough for developers, but a survey is better for common users

Copy link
Member

@uhafner uhafner left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks for adding that!

builder.append("\n")
.append(summary.getFailCount() - 10)
.append(" more test results are not shown here, view them on [Jenkins](")
.append(testsURL).append(")");

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Does this testsURL links to the JUnit summary page? If so, I think we should use different links for here and the detailsURL, maybe just the build page links for the detailsURL?

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

It links to the same place, I don’t think there’s any need to link differently the only place one would go it the test report from this check

@vladaurosh
Copy link

Hello.
Can we add option to remove messages "[Checks API] No suitable checks publisher found." ?

@timja
Copy link
Member Author

timja commented Oct 16, 2020

the option is there and documented in https://github.com/jenkinsci/junit-plugin#test-result-checks-for-github-projects
skipPublishingChecks: true

This should be discussed in jenkinsci/checks-api-plugin#38

@XiongKezhi
Copy link

I guess he wants to remove the status checks logs at all @timja

@vladaurosh And actually, that's something we are doing now: jenkinsci/checks-api-plugin#31

@timja
Copy link
Member Author

timja commented Oct 16, 2020

skipping publishing checks will do that, (although it would be nice to have a global switch or at least at the job level to opt out of the log)

@vladaurosh
Copy link

Thanks @timja and @XiongKezhi .
I'll wait for checks-api-plugin#31 to be done. :)

@vasilvestre
Copy link

I don't get how I should configure the publisher so my results are in github. Documentation doesn't really helps me here, any help is welcome

@jenkinsci jenkinsci locked as off-topic and limited conversation to collaborators Mar 4, 2022
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Integrate with checks-api plugin
6 participants