[Python] Minor fix to code format (#4172)

* test python e501 fix

* 2 spaces

* fix format with noqa: E501

* fix format, update samples
This commit is contained in:
William Cheng
2019-10-17 02:34:04 +08:00
committed by GitHub
parent f763b6dce3
commit 60d601ee26
15 changed files with 19 additions and 17 deletions

View File

@@ -104,7 +104,7 @@ class EnumArrays(object):
"""
allowed_values = ["fish", "crab"] # noqa: E501
if (self.local_vars_configuration.client_side_validation and
not set(array_enum).issubset(set(allowed_values))):
not set(array_enum).issubset(set(allowed_values))): # noqa: E501
raise ValueError(
"Invalid values for `array_enum` [{0}], must be a subset of [{1}]" # noqa: E501
.format(", ".join(map(str, set(array_enum) - set(allowed_values))), # noqa: E501

View File

@@ -108,7 +108,7 @@ class MapTest(object):
"""
allowed_values = ["UPPER", "lower"] # noqa: E501
if (self.local_vars_configuration.client_side_validation and
not set(map_of_enum_string.keys()).issubset(set(allowed_values))):
not set(map_of_enum_string.keys()).issubset(set(allowed_values))): # noqa: E501
raise ValueError(
"Invalid keys in `map_of_enum_string` [{0}], must be a subset of [{1}]" # noqa: E501
.format(", ".join(map(str, set(map_of_enum_string.keys()) - set(allowed_values))), # noqa: E501