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

[java] CommentDefaultAccessModifier - add co.elastic.clients.util.VisibleForTesting as default suppressed annotation #4285

Merged
merged 2 commits into from
Jan 10, 2023

Conversation

mluckam
Copy link
Contributor

@mluckam mluckam commented Jan 7, 2023

Describe the PR

The rule CommentDefaultAccessModifier ignores @VisibleForTesting as stated by the documentation:

This rule ignores by default all cases that have a @VisibleForTesting annotation or any JUnit5 annotation
https://pmd.github.io/pmd/pmd_rules_java_codestyle.html#commentdefaultaccessmodifier

This should also apply to the annotation co.elastic.clients.util.VisibleForTesting from the elastic provided java client, elasticsearch-java,.

Ready?

  • Added unit tests for fixed bug/feature
  • Passing all unit tests
  • Complete build ./mvnw clean verify passes (checked automatically by github actions)
  • Added (in-code) documentation (if needed)

@adangel adangel changed the title add co.elastic.clients.util.VisibleForTesting to collection of default suppressed annotations for rule CommentDefaultAccessModifier [java] CommentDefaultAccessModifier - add co.elastic.clients.util.VisibleForTesting to as default suppressed annotations Jan 9, 2023
Copy link
Member

@adangel adangel 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 the PR!

However, in the current state, we can't merge it: Please restore the unintended removal of ParameterizedTest.

Also I'd use a more accurate test description.

Thanks!

@mluckam mluckam force-pushed the elasticsearch_visiblefortesting branch from 3d24cb0 to 918aa04 Compare January 9, 2023 14:55
mluckam and others added 2 commits January 9, 2023 10:17
suppressed annotations for rule CommentDefaultAccessModifierRule
Co-authored-by: Andreas Dangel <andreas.dangel@adangel.org>
@mluckam mluckam force-pushed the elasticsearch_visiblefortesting branch from 918aa04 to f6504a6 Compare January 9, 2023 15:18
@adangel adangel changed the title [java] CommentDefaultAccessModifier - add co.elastic.clients.util.VisibleForTesting to as default suppressed annotations [java] CommentDefaultAccessModifier - add co.elastic.clients.util.VisibleForTesting as default suppressed annotations Jan 10, 2023
@adangel adangel changed the title [java] CommentDefaultAccessModifier - add co.elastic.clients.util.VisibleForTesting as default suppressed annotations [java] CommentDefaultAccessModifier - add co.elastic.clients.util.VisibleForTesting as default suppressed annotation Jan 10, 2023
@adangel adangel added this to the 6.54.0 milestone Jan 10, 2023
@pmd-test
Copy link

1 Message
📖 Compared to master:
This changeset changes 0 violations,
introduces 0 new violations, 0 new errors and 0 new configuration errors,
removes 0 violations, 2 errors and 7 configuration errors.
Full report

Generated by 🚫 Danger

Copy link
Member

@adangel adangel left a comment

Choose a reason for hiding this comment

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

Thanks, LGTM!

adangel added a commit that referenced this pull request Jan 10, 2023
adangel added a commit that referenced this pull request Jan 10, 2023
[java] CommentDefaultAccessModifier - add co.elastic.clients.util.VisibleForTesting as default suppressed annotation #4285
@adangel adangel merged commit f6504a6 into pmd:master Jan 10, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants