[PYTHON] Setting default value for Required variables (#10809)

* [req_vars_changes]

* Added new schema to generate samples to test the issue mentioned in the PR.

* Changed the variable name from setRequiredVars to initRequiredVars

* Added initRequiredVars as a generator additional property

* Regenerating the samples after rebasing the code with master branch

* Changed the description of additional property
This commit is contained in:
Akhil Nair
2022-03-30 21:22:00 +05:30
committed by GitHub
parent bb12861479
commit a6bcef5b16
56 changed files with 5032 additions and 0 deletions

View File

@@ -0,0 +1,39 @@
"""
OpenAPI Petstore
This spec is mainly for testing Petstore server and contains fake endpoints, models. Please do not use this for any other purpose. Special characters: \" \\ # noqa: E501
The version of the OpenAPI document: 1.0.0
Generated by: https://openapi-generator.tech
"""
import sys
import unittest
import petstore_api
from petstore_api.model.polygon import Polygon
from petstore_api.model.triangle_all_of import TriangleAllOf
globals()['Polygon'] = Polygon
globals()['TriangleAllOf'] = TriangleAllOf
from petstore_api.model.triangle import Triangle
class TestTriangle(unittest.TestCase):
"""Triangle unit test stubs"""
def setUp(self):
pass
def tearDown(self):
pass
def testTriangle(self):
"""Test Triangle"""
# FIXME: construct object with mandatory attributes with example values
# model = Triangle() # noqa: E501
pass
if __name__ == '__main__':
unittest.main()