Skip to content

chore: Migrate Gapic-Generator-Java to JUnit5#2771

Merged
lqiu96 merged 2 commits intomainfrom
gapic-generator-junit5
May 17, 2024
Merged

chore: Migrate Gapic-Generator-Java to JUnit5#2771
lqiu96 merged 2 commits intomainfrom
gapic-generator-junit5

Conversation

@lqiu96
Copy link
Member

@lqiu96 lqiu96 commented May 14, 2024

Fixes: #2725

Scope

This only modifies the unit tests inside the gapic-generator-java module. It does not modify the generated unit tests output from the generator. JUnit4 is still needed with default scope as it's used to generate the unit tests from the TestComposer:

<dependency>
<groupId>junit</groupId>
<artifactId>junit</artifactId>
<version>4.13.2</version>
</dependency>

Changes

  • Change the scope for Unit Tests from public to package-private
  • Parameterized tests updated to use @ParameterizedTests
  • Import updated to org.junit.jupiter.api.*

@product-auto-label product-auto-label bot added the size: l Pull request size is large. label May 14, 2024
@lqiu96 lqiu96 added the owlbot:run Add this label to trigger the Owlbot post processor. label May 15, 2024
@gcf-owl-bot gcf-owl-bot bot removed the owlbot:run Add this label to trigger the Owlbot post processor. label May 15, 2024
@lqiu96 lqiu96 marked this pull request as ready for review May 15, 2024 18:21
@lqiu96 lqiu96 requested a review from a team May 15, 2024 18:21
@lqiu96 lqiu96 force-pushed the gapic-generator-junit5 branch from 8bd2a43 to 9f910ea Compare May 16, 2024 20:27
@lqiu96 lqiu96 requested a review from alicejli May 16, 2024 20:31
@sonarqubecloud
Copy link

Quality Gate Passed Quality Gate passed for 'gapic-generator-java-root'

Issues
3 New issues
0 Accepted issues

Measures
0 Security Hotspots
No data about Coverage
0.0% Duplication on New Code

See analysis details on SonarCloud

@sonarqubecloud
Copy link

Quality Gate Passed Quality Gate passed for 'java_showcase_integration_tests'

Issues
0 New issues
0 Accepted issues

Measures
0 Security Hotspots
No data about Coverage
No data about Duplication

See analysis details on SonarCloud

@lqiu96 lqiu96 merged commit 94ef4f4 into main May 17, 2024
@lqiu96 lqiu96 deleted the gapic-generator-junit5 branch May 17, 2024 17:13
lqiu96 added a commit that referenced this pull request May 22, 2024
Fixes: #2725

# Scope
This *only* modifies the unit tests inside the gapic-generator-java
module. It does not modify the generated unit tests output from the
generator. JUnit4 is still needed with default scope as it's used to
generate the unit tests from the TestComposer:
https://github.com/googleapis/sdk-platform-java/blob/96e6626eb2dda867b5d8d81f3ec706b5a995a3c2/gapic-generator-java/pom.xml#L446-L450

# Changes
- Change the scope for Unit Tests from public to package-private
- Parameterized tests updated to use `@ParameterizedTests`
- Import updated to `org.junit.jupiter.api.*`
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

size: l Pull request size is large.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Migrate Junit 4 to Junit 5: gapic-generator-java

4 participants