chore: declare test-jar in GAX's testlib artifacts#1474
Conversation
12bdf6d to
2484061
Compare
| <dependency> | ||
| <groupId>com.google.api</groupId> | ||
| <artifactId>gax</artifactId> | ||
| <type>test-jar</type> |
There was a problem hiding this comment.
Can you add source code comment why this test-jar is important?
|
Assuming this is the correct fix, will we need any change in the users of GAX’s testlib-classifier users? |
I think they need to add I found out this in the failing Kokoro checks |
|
My own confirmation. Remove local Maven repository cache: Checkout main (not this pull request): Open gapic-generator-java project in IntelliJ and tried running the gapic-generator-java module's unit tests. It shows the error. Now checkout this pull request. Run the unit tests in IntelliJ. It succeeded. |
|
@blakeli0 Can you confirm this pull request fixes the problem in your IntelliJ? (It worked form me) |
| <groupId>com.google.api</groupId> | ||
| <artifactId>gax</artifactId> | ||
| <version>2.23.3-SNAPSHOT</version><!-- {x-version-update:gax:current} --> | ||
| <type>test-jar</type> |
There was a problem hiding this comment.
@JoeWang1127 'dependencies.dependency.version' for com.google.api:gax:jar:testlib is missing. @ line 80, column 21 came from the BOM's declaration of the artifacts. Do you really need that?
There was a problem hiding this comment.
I think this line is needed to bring the test code.
There was a problem hiding this comment.
A BOM doesn't determine what code goes to JAR file.
There was a problem hiding this comment.
There's an error in gapic-generator-java module if I delete this line and reload the project:
'dependencies.dependency.version' for com.google.api:gax-grpc:test-jar:testlib is missing.
There was a problem hiding this comment.
OK it’s for IntelliJ. Then it makes sense.
Yes, I verified that it's working now with Joe's fix. Thank you so much @JoeWang1127 ! |
| <groupId>com.google.api</groupId> | ||
| <artifactId>gax</artifactId> | ||
| <version>2.23.3-SNAPSHOT</version><!-- {x-version-update:gax:current} --> | ||
| <classifier>testlib</classifier> |
There was a problem hiding this comment.
Trying an additional entry that does not carry "test-jar".
|
Kudos, SonarCloud Quality Gate passed!
|
…enerator-java into chore/enable-test-jar
Source-Link: googleapis/synthtool@7a220e2 Post-Processor: gcr.io/cloud-devrel-public-resources/owlbot-java:latest@sha256:6d4e3a15c62cfdcb823d60e16da7521e7c6fc00eba07c8ff12e4de9924a57d28
Source-Link: googleapis/synthtool@7a220e2 Post-Processor: gcr.io/cloud-devrel-public-resources/owlbot-java:latest@sha256:6d4e3a15c62cfdcb823d60e16da7521e7c6fc00eba07c8ff12e4de9924a57d28











Thank you for opening a Pull Request! For general contributing guidelines, please refer to contributing guide
Before submitting your PR, there are a few things you can do to make sure it goes smoothly:
Fixes #1144 ☕️