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

QueryDSL APT processing break JaCoCo code coverage reporting #9990

Closed
poikilotherm opened this issue Oct 10, 2023 · 0 comments · Fixed by #10041
Closed

QueryDSL APT processing break JaCoCo code coverage reporting #9990

poikilotherm opened this issue Oct 10, 2023 · 0 comments · Fixed by #10041
Labels
Component: Code Infrastructure formerly "Feature: Code Infrastructure"
Milestone

Comments

@poikilotherm
Copy link
Contributor

As can be seen in the action logs (here's an example, see under "Deposit Code Coverage"), the Coveralls plugin cannot find sources for classed generated by QueryDSL.

Usually these should be ignored by JaCoCo, but they are present as the default annotation javax.annotation.processing.Generated has retention scope SOURCE and is no longer visible to JaCoCo.

CoverAll Maven plugin doc says: do not include generated sources. (Which makes sense - why would we count that...)

poikilotherm added a commit that referenced this issue Oct 10, 2023
Classed generated by QueryDSL are included in the JaCoCo report
because of not using an `@Generated` annotation that is of retention
scope "runtime" or "class".

This commit moves the APT dependency for QueryDSL to the Maven compiler
plugin configuration and annotation processor, which makes it
configurable.

Switching the annotation to be used with QueryDSL generated classes
fixes the code coverage reporting problem.

See also: querydsl/querydsl#3131 (comment)
See also: https://querydsl.com/static/querydsl/latest/reference/html/ch03s03.html
@poikilotherm poikilotherm added the Component: Code Infrastructure formerly "Feature: Code Infrastructure" label Oct 10, 2023
@pdurbin pdurbin added this to the 6.1 milestone Oct 27, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Component: Code Infrastructure formerly "Feature: Code Infrastructure"
Projects
None yet
2 participants