feat: Publish maven packages without use of Gradle - #351
Conversation
| try { | ||
| await mvnTarget.closeAndReleaseRepository(); | ||
| } catch (e) { | ||
| // no-empty | ||
| } |
There was a problem hiding this comment.
Why not something like expect(...).not.toThrow()?
There was a problem hiding this comment.
Because we actually want to throw here
There was a problem hiding this comment.
Then shouldn't it be more like:
expect(mvnTarget.closeAndReleaseRepository).rejects.toThrowErrorMatchingInlineSnapshot()?
Right now there's nothing asserting that we have thrown anything.
There was a problem hiding this comment.
Because imo assertions should match the name of the test.
should not release repostiory if it was not closed properly
And assertion is that releaseRepository was never called. closeAndReleaseRepository is only a setup trigger.
There was a problem hiding this comment.
Because imo assertions should match the name of the test
Yeah, that makes sense.
And assertion is that releaseRepository was never called. closeAndReleaseRepository is only a setup trigger.
I think a comment here instead of // on-empty would go a long way to communicate this to other developers such as myself and @iker-barriocanal 馃檪
There was a problem hiding this comment.
Fair point, will keep that in mind :)
This PR utilizes direct API calls to close and publish packages to Nexus, instead of going through a 3rd party Gradle plugin.
Tests and verification are still TBD, but it's already EOD, and wanted to get this PR out for an initial review.
This change will also make #278 obsolete.