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

Enable AddExtensionIT.testAddExtensionWithASingleExtensionToSubmodule #16564

Merged
merged 1 commit into from
Apr 16, 2021
Merged

Enable AddExtensionIT.testAddExtensionWithASingleExtensionToSubmodule #16564

merged 1 commit into from
Apr 16, 2021

Conversation

famod
Copy link
Member

@famod famod commented Apr 15, 2021

#14164 was fixed via #16290

/cc @aloubyansky

@gsmet gsmet merged commit 8f7d247 into quarkusio:main Apr 16, 2021
@quarkus-bot quarkus-bot bot added this to the 2.0 - main milestone Apr 16, 2021
@famod famod deleted the testAddExtensionWithASingleExtensionToSubmodule branch April 16, 2021 20:18
@@ -61,7 +61,8 @@ void testAddExtensionWithASingleExtensionToSubmodule() throws MavenInvocationExc
expected.setArtifactId(VERTX_ARTIFACT_ID);
assertThat(contains(model.getDependencies(), expected)).isTrue();

assertThat(model.getDependencyManagement().getDependencies()).isEmpty();
assertThat(Optional.ofNullable(model.getDependencyManagement())
.map(DependencyManagement::getDependencies).orElse(Collections.emptyList())).isEmpty();
Copy link
Member

Choose a reason for hiding this comment

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

How about model.getDependencyManagement() == null ? Collections.emptyList() : model.getDependencyManagement().getDependencies();

Copy link
Member Author

Choose a reason for hiding this comment

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

Guillaume merged it already. 😉
I'm a bit of a DRY fanatic, so I personally don't like the redudant calls that come with that pattern.

Copy link
Member

Choose a reason for hiding this comment

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

Doesn't your code result in more calls? And, I guess, it's a lot more JVM "work" for the same result.

Copy link
Member Author

Choose a reason for hiding this comment

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

Yes, more calls and thus a bit more work, but no repetition.
It's a matter of personal preference, YMMV.
If your version is more in line with what is usually being used in Quarkus then I'll try to remember that next time.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants