mirror of
https://github.com/OpenAPITools/openapi-generator.git
synced 2025-12-08 15:16:14 +00:00
[python-client] Add model default values (#1776)
* Adds two models to the v2.0 spec, uses examples as defaults in python client * Adds array default and type_holder_default and type_holder_example tests * Re-generated python security client with ./bin/security/python-petstore.sh * Changes comment text, rebased master * Updates client + server samples * Adds missing samples updates * Changes python client to look for true or false with booleans in toDefaultValue * Changes boolean casting to use Boolean.valueOf * Adds deserialization fix for python tests * Changes Mock to namedtuple in python deserialization tests * Actually remove unittest.mock
This commit is contained in:
committed by
William Cheng
parent
189849319c
commit
539ec23298
@@ -8,7 +8,7 @@ Method | HTTP request | Description
|
||||
|
||||
|
||||
# **call_123_test_special_tags**
|
||||
> Client call_123_test_special_tags(client)
|
||||
> Client call_123_test_special_tags(body)
|
||||
|
||||
To test special tags
|
||||
|
||||
@@ -24,11 +24,11 @@ from pprint import pprint
|
||||
|
||||
# create an instance of the API class
|
||||
api_instance = petstore_api.AnotherFakeApi()
|
||||
client = petstore_api.Client() # Client | client model
|
||||
body = petstore_api.Client() # Client | client model
|
||||
|
||||
try:
|
||||
# To test special tags
|
||||
api_response = api_instance.call_123_test_special_tags(client)
|
||||
api_response = api_instance.call_123_test_special_tags(body)
|
||||
pprint(api_response)
|
||||
except ApiException as e:
|
||||
print("Exception when calling AnotherFakeApi->call_123_test_special_tags: %s\n" % e)
|
||||
@@ -38,7 +38,7 @@ except ApiException as e:
|
||||
|
||||
Name | Type | Description | Notes
|
||||
------------- | ------------- | ------------- | -------------
|
||||
**client** | [**Client**](Client.md)| client model |
|
||||
**body** | [**Client**](Client.md)| client model |
|
||||
|
||||
### Return type
|
||||
|
||||
|
||||
Reference in New Issue
Block a user