Commit Graph

9842 Commits

Author SHA1 Message Date
wing328
90a0b7a7e2 add python tornado test to travis 2017-11-13 12:05:18 +08:00
Tomasz Prus
4e967e696c [Python/tornado] add integration tests and fix bugs (#6925)
* tests: add integration test for python-tornado

* [python-tornado-client] tests: increase timeout for test_upload_file

* [python-tornado-client] fix: tornado client passes tests
2017-11-13 12:03:55 +08:00
Alexandre Demode
63d28cf75b Fix PHP passes response body to ApiException (#6923) 2017-11-13 11:30:46 +08:00
Shuma Yoshioka
053061ec9f [TypeScript][Node] Resolve TS2532 error (#6932)
* [TypeScript][Node] Resolve TS2532 error

* Run `bin/typescript-node-petstore-all.sh`

* Run `bin/security/typescript-node.sh`
2017-11-13 11:23:56 +08:00
wing328
4a38ee283c Merge branch 'test_php' 2017-11-12 23:23:23 +08:00
wing328
f34aca62f6 skip "all" shell script 2017-11-12 22:42:02 +08:00
wing328
2ef65d1488 Merge branch 'master' of https://github.com/swagger-api/swagger-codegen 2017-11-12 22:23:30 +08:00
wing328
444a05ce21 minor formatting change 2017-11-12 22:21:54 +08:00
wing328
c515dd82ff Merge branch 'master' of https://github.com/swagger-api/swagger-codegen 2017-11-12 22:16:37 +08:00
etherealjoy
ca58053339 Fixes Issue #6841, Map for accessing additionalProperties is generated. (#6886)
The issue #6884 is still present and requires fixing outside of mustache file as well.
2017-11-12 22:16:26 +08:00
William Cheng
6739481a5d
add tsloughter as owner erlang 2017-11-12 22:07:12 +08:00
Tristan Sloughter
b9651e5775 WIP: initial commit for Erlang client generator (#6502)
* WIP: initial commit for Erlang client generator

* add models types and function type specs

* fix type specs when models are the type and support QS lists

* make method lowercase in postprocessoperations

* add model encode function

* add erlang client sample

* add windows client sample script

* proper return type spec and handle return error messages
2017-11-12 22:02:05 +08:00
wing328
0d55c12a63 add back php client test 2017-11-12 21:59:47 +08:00
William Cheng
fd220147ae
Switch Travis image from MacOS to Linux (#6937)
* remove jdk7 check

* comment out some installation

* update npm

* comment out ts angular tests

* restore ts angular2 test

* restore bash test

* add back new config, clean up commented items
2017-11-12 21:50:11 +08:00
William Cheng
d76e37277a
add link to ebook 2017-11-11 14:51:35 +08:00
Greg Marzouka
f921f4f4da [Scala] Default case class Option types to None for non-required fields (#6790)
* [Scala] Default case class Option types to None

* Update Petstore sample
2017-11-10 15:57:40 +08:00
Gustavo Paz
b404dafa02 Issue 6694 2.3.0 (#6845)
* The get method template is modified to return the value of the enum instead of the enum itself.

* Update of the Petstore CXF server sample

* Update of the Petstore CXF client sample

* Update of the Petstore CXF server annotated base path sample

* Update of the Petstore CXF server non spring application sample
2017-11-10 15:32:05 +08:00
Andrew Norman
372a08763d adding "Read Timeout" getters and setters for the Jersey and OkHttp (#6853)
* adding "Read Timeout" getters and setters for the Jersey and OkHttp
based ApiClients

adding "Write Timeout" getters and setters for the OkHttp based
ApiClient

adding tests for the OkHttpClient covering the new getters and setters

* generated files from the bin scripts
2017-11-10 12:12:40 +08:00
wing328
141fc7e8c7 Merge branch 'master' of https://github.com/swagger-api/swagger-codegen 2017-11-09 22:41:22 +08:00
afrolovsky
9a44512d03 @JsonProperty annotation for jaxrs-spec server model classes (#6911) (#6916) 2017-11-09 21:46:26 +08:00
wing328
3355c92970 Merge branch 'master' of https://github.com/swagger-api/swagger-codegen 2017-11-09 21:46:00 +08:00
wing328
9dea435104
add kenjonese-cisco to python tech committee 2017-11-09 21:43:47 +08:00
François Rosé
485b186129 [CppRest] Unique header guards (#6904)
* [CppRest] Generate unique header guards based on the package names.

* [CppRest] Update cpprest petstore client sample.
2017-11-09 17:59:45 +08:00
François Rosé
7a83081f18 [CppRest] Remove U macro (#6903)
* [CppRest] Replace U macro with conversion function for default string values.

* [CppRest] Replace U macro with conversion function in templates.

* [CppRest] Update cpprest petstore client sample.
2017-11-09 17:58:21 +08:00
Jim Schubert
92ac1edd78 [csharp] Treat enum models consistently (#6851)
* [csharp] Treat enum models consistently

C# works differently from most languages in that enums are not
considered objects. This means default(EnumType) will choose a default
of the first enum option. This isn't desirable because it breaks the
required = false functionality of swagger specs, which defines a
property which isn't required to exist in the message body.

Rather than force consumers to use enum values such as UNSPECIFIED, UNKNOWN,
NOT_SET, etc... we can treat enums as primitives. This means any
non-required enum will become Nullable<EnumType> regardless of whether
it is defined as an inline enum or a referenced enum model.

* Categorizing C# integration test for enums as general

* [csharp] Remove enum-ref integration test

* [csharp] Clean up general enum support integration test, validate different enum usage cases.
2017-11-09 17:14:47 +08:00
wing328
8b251555ac update php symfony petstore, remove spaces in empty line 2017-11-09 16:36:25 +08:00
cydrickn
fbc28797d1 [PHP][Symfony] Update Controller.mustache (#6842)
* Update Controller.mustache

* Use debug instead of environment
2017-11-09 16:29:41 +08:00
Jinkui Shi
92a1c3a449 [issue-6860] fix NPE of Could not generate api (#6868) 2017-11-07 15:46:20 +08:00
Keni Steward
39a9c5587f [Typescript][Node] Fixes inccorect enum generation for enumsMap when Array<Enum> is defined fixes part of Issue #5681 (#6862) 2017-11-07 01:19:58 +08:00
Keni Steward
626fa7531b [TypeScript][Angular] Attempts to fix issues that causes enums that are not generated with a class to not generate correctly (#6833)
* Attempts to fix issues that causes enums that are not generated with a class to not generate correctly

* Fixed issue with incorrectly generating enums
2017-11-05 16:34:24 +08:00
Jeffrey Slort
cf813f5c8e Feature/replace isomorphic fetch with portable fetch (#6739)
* Replaced isomorphic fetch with portable fetch

* Ran scripts in bin

* reference custom.d.ts in api.ts

* ran scripts and added custom.d.ts files to git

* Ran scripts in bin after merge

* regenerated security tests
2017-11-05 15:37:54 +08:00
wing328
2bce479c1c
minor code format enhancement to ts angualr (#6888) 2017-11-05 12:05:45 +08:00
wing328
37184a1cd8
Minor fix to body parameter in required parameter list (#6885)
* minor fix to required parameter list

* better if then else block
2017-11-05 10:22:36 +08:00
Jon Schoning
cd1c2b13e3 [haskell-http-client] refactor & promote accept mimetype to request; simplify templates (#6866)
* add AuthMethodException

* rename cli prop

* simplify templates
2017-11-05 01:41:53 +08:00
Meindert Deen
a5586044cd Implemented fix for #6006. Mime-type support (#6751)
* Implemented fix for #6006. Mime-type support for accepts and
content-type.

* Review comments of @macjohnny incorporated

* merge with latest and retest

* merge with latest and retest. Now correctly generated with new Maven build
2017-11-05 00:26:42 +08:00
Kenny Jones
b6699f6068 [python] Convert unicode to six.u (#6881)
`unicode` does not exist in py3, therefore since six is already imported
switch to using `six.u` so that `unicode` is used on py2 and `str` is used
on py3.
2017-11-04 23:24:51 +08:00
Jim Schubert
7b269eaf4a Kotlin sanitize model names 6864 (#6874)
* [kotlin] better sanitize model names

* [kotlin] Regenerate samples
2017-11-04 23:23:08 +08:00
stkrwork
659e64206a - Updated cpp generators to name boolean getter functions with an is at the beginning (ex. isActive) (#6880) 2017-11-04 22:04:38 +08:00
Giulio Pulina
4dafa5b92a Updated version (2.2.3) in swagger-codegen-maven-plugin example in README (#6876) 2017-11-03 22:08:30 +08:00
wing328
cf5eba87bd update circleci to cover java google-api client, update Java petstore
samples
2017-11-03 18:49:32 +08:00
Charles Capps
c2eb53ab1d [Java] Templates to support google-api-client library (#6838)
* Add support for the google-api-client

* When there's no return type, just return (no parsing the response)

* Update the deserialization to use a Jackson typeref.

* Delete the auth mustache files as we don't need them

* Stop generating unneeded auth files; get SBT/gradle working with the generated module

* Add builder-style methods to the google-api-client ApiClient for getting API instances

* Update the README to reflect the new client library option

* Generated overloaded methods to send query params as a Map<String, Object>

* Add files for Sample codes

* Add type in angle brackets to support Java 6

* Required query params must be added to the Map of params. Update sample code.

* Use explicit types instead of diamonds to support Java6 in one more place.

* Clean up javadoc warnings in generated code / remove pointless return statements

* Clean up extra newlines in generated code
2017-11-03 18:46:07 +08:00
Jim Schubert
0ee46c32a2 [all] Better error message for missing libraries (#6856) 2017-11-02 17:55:42 +08:00
Jean-François Côté
16373b9f70 Fix the fake endpoint example. Now all cases are handled by the java play framework! (#6850) 2017-11-02 17:54:34 +08:00
Jim Schubert
e7594c42d0 [kotlin] Nested enum naming fix, and naming options via CLI (#6858)
* [kotlin] Nested enum naming fix, and naming options via CLI

* [kotlin] Add option test for enum property naming

* [kotlin] Escape all reserved/keywords for enums
2017-11-02 17:35:11 +08:00
wing328
86b266b02f
[TS][Anuglar] Update Travis CI to cover TS Angular 4.3 petstore client (#6844)
* add CI to TS Angular 4.3

* comment out ts cache direcotries
2017-11-02 17:32:32 +08:00
Erik Timmers
980dd7c6ab Add TypeScript default value mappers (#6828)
Fixes #6765.
2017-11-02 17:16:30 +08:00
Akihito Nakano
e8635632a4 [PHP] Fix #6770: Debug flag is not passed (#6808)
* Add testcase which reproduces issue #6770

* Pass debug option if needed

* Update samples

* bin/php-petstore.sh
* bin/security/php-petstore.sh

* Api throws exception when failed to open debug file

* Pass debug option if needed (Async)

* Extract instance method

* Update samples

* bin/php-petstore.sh
* bin/security/php-petstore.sh
2017-11-02 17:14:00 +08:00
wing328
81d6b18cf7 Merge branch 'master' of https://github.com/swagger-api/swagger-codegen 2017-11-02 14:04:28 +08:00
wing328
1c19891db3 make nancyfx-petstore-server-async.sh executable 2017-11-02 14:04:12 +08:00
Kenny Jones
74f70a1924 [python-client] Modify python templates to resolve linting errors (#6839)
The linting results for the generated samples are as follows
where the first number is the BEFORE and the second is AFTER.

pyclient            7714 vs. 120
pyclient3           7717 vs. 120
pyclient3-asyncio   7584 vs. 120
pyclient-tornado    7633 vs. 120
pyclient3-tornado   7633 vs. 120

For the complete details please see the following gist.
https://gist.github.com/kenjones-cisco/2eb69a7e8db75e9fd53789f01570d9f2

Enforces linting for python clients by running flake8 for the generated
python client.
2017-11-02 00:47:14 +08:00