forked from loafle/openapi-generator-original
[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.
This commit is contained in:
@@ -3,7 +3,7 @@
|
||||
"""
|
||||
Swagger 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: \" \\
|
||||
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
|
||||
|
||||
OpenAPI spec version: 1.0.0
|
||||
Contact: apiteam@swagger.io
|
||||
@@ -13,17 +13,15 @@
|
||||
|
||||
from __future__ import absolute_import
|
||||
|
||||
import os
|
||||
import sys
|
||||
import unittest
|
||||
|
||||
import petstore_api
|
||||
from petstore_api.models.dog import Dog # noqa: E501
|
||||
from petstore_api.rest import ApiException
|
||||
from petstore_api.models.dog import Dog
|
||||
|
||||
|
||||
class TestDog(unittest.TestCase):
|
||||
""" Dog unit test stubs """
|
||||
"""Dog unit test stubs"""
|
||||
|
||||
def setUp(self):
|
||||
pass
|
||||
@@ -32,11 +30,9 @@ class TestDog(unittest.TestCase):
|
||||
pass
|
||||
|
||||
def testDog(self):
|
||||
"""
|
||||
Test Dog
|
||||
"""
|
||||
"""Test Dog"""
|
||||
# FIXME: construct object with mandatory attributes with example values
|
||||
#model = petstore_api.models.dog.Dog()
|
||||
# model = petstore_api.models.dog.Dog() # noqa: E501
|
||||
pass
|
||||
|
||||
|
||||
|
||||
Reference in New Issue
Block a user