Jim Schubert ee1cbf6f4b
[bug][maven] Fix custom windows classpaths in maven plugin (#7587)
* [maven] Fallback to templates using classpath rather than OS-specific paths

Previous checks would cause logic in Windows to return early, for
built-in templates only. This reorganizes and simplifies the ordering
behavior.

* Match classpath check in WorkflowSettings with that in TemplateManager

* [maven] Much needed unit/integration tests

This follows similar approach used in PMD and other plugins managed by
maven.

Unit tests simply verify we can load configuration as expected into the
Mojo.

Integration tests execute actual sample projects bound to the current
build's Maven plugin. This uses maven-invoker-plugin, which also allows
for specifying the maven options in invoker.properties to execute the test.
It also provides a verification framework using groovy files with the
required naming convention of "verify.groovy". This allows us to quickly
and easily check that certain files are outputted by generation, and we
may also spotcheck file contents.

templateResourcePath option is skipped on windows. I've tested back to
version 3.3.3 and this doesn't seem to have worked consistently with how
the property works on non-Windows.

* Set groovy 3.0.5 for test harness

* Print stacktrace on Maven error in Travis

* [maven] Set groovy version in tests to supported in Java 11+

* Puts maven integration tests in separate profile called 'integration'
2020-10-18 12:05:56 -04:00

22 lines
457 B
Plaintext
Vendored

# TEST TEST TEST
# {{artifactId}}
{{appName}}
- API version: {{appVersion}}
{{^hideGenerationTimestamp}}
- Build date: {{generatedDate}}
{{/hideGenerationTimestamp}}
{{#appDescriptionWithNewLines}}{{{appDescriptionWithNewLines}}}{{/appDescriptionWithNewLines}}
{{#infoUrl}}
For more information, please visit [{{{infoUrl}}}]({{{infoUrl}}})
{{/infoUrl}}
*Automatically generated by the [OpenAPI Generator](https://openapi-generator.tech)*
… etc.