Commit Graph

3 Commits

Author SHA1 Message Date
Thibault Duperron
42a9368d91 Fix JaxRS-Jersey template for files upload (#2570)
* Fix JaxRS-Jersey template for files

For #2474

* Samples

* PR Review

* Samples

* Add openapi3 to sample script jaxrs server all

* Sample
2019-04-05 23:58:28 +08:00
Adrian Price
2985c0f0b8 JAX-RS/CXF 1158 Options to generate fully functional method bodies passing fully populated test data (#1879)
* add option to generate alias as model

* [JAXRS/CXF] Emit method bodies, test data (#1158)

New jaxrs-cxf-extended generator with options:
 - supportMultipleSpringServices Support generation of Spring services
   from multiple specifications
 - generateOperationBody (boolean) Enables generation of fully
   functional test/service method bodies that pass/return random
   but valid values & models.
 - loadTestDataFromFile (boolean) When true, generated method bodies
   load test data from a generated JSON file. When false, generated
   method bodies contain inline code to construct the test data.
 - testDataFile (string) The path of a JSON file to contain generated
   test data. The file is initially generated but editable; edits are
   preserved by subsequent generations.
 - testDataControlFile (string) The path of a JSON file to control test
   data generation - specifically, to control the number of items
   required in array properties, structured by API class
   / operation name / parameter name. The file is initially generated
   but editable; edits are preserved by subsequent generations.
 - tests for the jaxrs-cxf-extended generator, including the new options
Bug fixes:
 - fix bug (DefaultGenerator): handle absolute paths in supporting file
   spec
 - fix bug (DefaultCodegen): process enums in allVars
 - fix bug (AbstractJavaCodegen): support multiple inheritance via
   allOf (inheritance code deleted, as a subsequent pull broke it)
 - fix bug (JavaCXFServerCodegen): use operationId instead of nickname
(gets out of step with duplicate operationIds)
 - fix bug (JavaCXFServerCodegen): set appropriate default
consumes/produces for operations with body parameters or non-void
returns (CXF providers don't handle */*)
 - fix indentation (DefaultCodegen)
 - add support for a system property openapitools.implementation.version
to specify the package implementation version when running non-JAR'd
classes in an IDE (otherwise {{{generatorVersion}}} evaluates to
'unset'.

* reformat code

* make sh executable

* fix template folder

* fix template folder, update samples

* run test data manually to avoid ci failure
2019-03-06 08:58:11 +08:00
Jérémie Bresson
8de5c62cf2
Add JaxRS to bin/ensure-up-to-date (#248)
* Create bin/java-jaxrs-petstore-server-all.sh
* Run bin/java-jaxrs-petstore-server-all.sh
* Add 'bin/java-jaxrs-petstore-server-all.sh' to 'bin/ensure-up-to-date'
2018-06-09 08:54:27 +02:00