Skip to content
This repository has been archived by the owner on Aug 2, 2024. It is now read-only.

chore: set up java 21 in unit tests #498

Merged
merged 1 commit into from
Oct 19, 2023
Merged

Conversation

JoeWang1127
Copy link
Contributor

@JoeWang1127 JoeWang1127 commented Oct 18, 2023

Fix #492

@@ -3,6 +3,8 @@
<Match>
<Or>
<Bug pattern="DM_STRING_CTOR"/>
<Bug pattern="EI_EXPOSE_REP"/>
<Bug pattern="EI_EXPOSE_REP2"/>
Copy link
Contributor Author

Choose a reason for hiding this comment

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

Exclude EI_EXPOSE_REP and EI_EXPOSE_REP2. We can address them in dedicated PR.

[ERROR] Medium: new com.google.cloud.tools.maven.cloudsdk.CloudSdkAppEngineFactory(CloudSdkMojo) may expose internal representation by storing an externally mutable object into CloudSdkAppEngineFactory.mojo [com.google.cloud.tools.maven.cloudsdk.CloudSdkAppEngineFactory] At CloudSdkAppEngineFactory.java:[line 56] EI_EXPOSE_REP2
[ERROR] Medium: com.google.cloud.tools.maven.cloudsdk.CloudSdkMojo.getMavenProject() may expose internal representation by returning CloudSdkMojo.mavenProject [com.google.cloud.tools.maven.cloudsdk.CloudSdkMojo] At CloudSdkMojo.java:[line 125] EI_EXPOSE_REP
[ERROR] Medium: com.google.cloud.tools.maven.cloudsdk.CloudSdkMojo.getMavenSession() may expose internal representation by returning CloudSdkMojo.mavenSession [com.google.cloud.tools.maven.cloudsdk.CloudSdkMojo] At CloudSdkMojo.java:[line 129] EI_EXPOSE_REP
[ERROR] Medium: com.google.cloud.tools.maven.run.AbstractRunMojo.getAdditionalArguments() may expose internal representation by returning AbstractRunMojo.additionalArguments [com.google.cloud.tools.maven.run.AbstractRunMojo] At AbstractRunMojo.java:[line 119] EI_EXPOSE_REP
[ERROR] Medium: com.google.cloud.tools.maven.run.AbstractRunMojo.getEnvironment() may expose internal representation by returning AbstractRunMojo.environment [com.google.cloud.tools.maven.run.AbstractRunMojo] At AbstractRunMojo.java:[line 115] EI_EXPOSE_REP
[ERROR] Medium: com.google.cloud.tools.maven.run.AbstractRunMojo.getJvmFlags() may expose internal representation by returning AbstractRunMojo.jvmFlags [com.google.cloud.tools.maven.run.AbstractRunMojo] At AbstractRunMojo.java:[line 103] EI_EXPOSE_REP

Copy link
Contributor

Choose a reason for hiding this comment

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

I also feel these are inevitable for these getters.

@JoeWang1127 JoeWang1127 marked this pull request as ready for review October 18, 2023 17:08
@JoeWang1127 JoeWang1127 requested a review from suztomo October 18, 2023 17:08
@JoeWang1127 JoeWang1127 changed the title chore: upgrade spotbugs plugin to 4.7 chore: set up java 21 in unit tests Oct 18, 2023
@JoeWang1127 JoeWang1127 merged commit c065263 into master Oct 19, 2023
5 checks passed
@JoeWang1127 JoeWang1127 deleted the chore/update-java21 branch October 19, 2023 14:35
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Set up Java 21 test
2 participants