Skip to content

Commit 9693f0f

Browse files
committed
use localhost
1 parent ecd2225 commit 9693f0f

5 files changed

Lines changed: 11 additions & 6 deletions

File tree

modules/openapi-generator/src/test/resources/3_0/python/petstore-with-fake-endpoints-models-for-testing.yaml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -397,6 +397,7 @@ paths:
397397
description: Order not found
398398
/user:
399399
servers:
400+
- url: 'http://localhost/v2'
400401
- url: 'http://petstore.swagger.io/v2'
401402
- url: 'http://path-server-test.petstore.local/v2'
402403
- url: 'http://{server}.swagger.io:{port}/v2'

samples/openapi3/client/petstore/python-aiohttp/petstore_api/api/user_api.py

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -54,7 +54,7 @@ async def create_user(
5454
_request_auth: Optional[Dict[StrictStr, Any]] = None,
5555
_content_type: Optional[StrictStr] = None,
5656
_headers: Optional[Dict[StrictStr, Any]] = None,
57-
_host_index: Annotated[StrictInt, Field(ge=0, le=3)] = 0,
57+
_host_index: Annotated[StrictInt, Field(ge=0, le=4)] = 0,
5858
) -> None:
5959
"""Create user
6060
@@ -120,7 +120,7 @@ async def create_user_with_http_info(
120120
_request_auth: Optional[Dict[StrictStr, Any]] = None,
121121
_content_type: Optional[StrictStr] = None,
122122
_headers: Optional[Dict[StrictStr, Any]] = None,
123-
_host_index: Annotated[StrictInt, Field(ge=0, le=3)] = 0,
123+
_host_index: Annotated[StrictInt, Field(ge=0, le=4)] = 0,
124124
) -> ApiResponse[None]:
125125
"""Create user
126126
@@ -186,7 +186,7 @@ async def create_user_without_preload_content(
186186
_request_auth: Optional[Dict[StrictStr, Any]] = None,
187187
_content_type: Optional[StrictStr] = None,
188188
_headers: Optional[Dict[StrictStr, Any]] = None,
189-
_host_index: Annotated[StrictInt, Field(ge=0, le=3)] = 0,
189+
_host_index: Annotated[StrictInt, Field(ge=0, le=4)] = 0,
190190
) -> RESTResponseType:
191191
"""Create user
192192
@@ -243,6 +243,7 @@ def _create_user_serialize(
243243
) -> RequestSerialized:
244244

245245
_hosts = [
246+
'http://localhost/v2',
246247
'http://petstore.swagger.io/v2',
247248
'http://path-server-test.petstore.local/v2',
248249
'http://{server}.swagger.io:{port}/v2'

samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/api/user_api.py

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -99,6 +99,7 @@ async def create_user_with_http_info(self, user : Annotated[User, Field(..., des
9999
"""
100100

101101
_hosts = [
102+
'http://localhost/v2',
102103
'http://petstore.swagger.io/v2',
103104
'http://path-server-test.petstore.local/v2',
104105
'http://{server}.swagger.io:{port}/v2'

samples/openapi3/client/petstore/python-pydantic-v1/petstore_api/api/user_api.py

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -112,6 +112,7 @@ def create_user_with_http_info(self, user : Annotated[User, Field(..., descripti
112112
"""
113113

114114
_hosts = [
115+
'http://localhost/v2',
115116
'http://petstore.swagger.io/v2',
116117
'http://path-server-test.petstore.local/v2',
117118
'http://{server}.swagger.io:{port}/v2'

samples/openapi3/client/petstore/python/petstore_api/api/user_api.py

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -54,7 +54,7 @@ def create_user(
5454
_request_auth: Optional[Dict[StrictStr, Any]] = None,
5555
_content_type: Optional[StrictStr] = None,
5656
_headers: Optional[Dict[StrictStr, Any]] = None,
57-
_host_index: Annotated[StrictInt, Field(ge=0, le=3)] = 0,
57+
_host_index: Annotated[StrictInt, Field(ge=0, le=4)] = 0,
5858
) -> None:
5959
"""Create user
6060
@@ -120,7 +120,7 @@ def create_user_with_http_info(
120120
_request_auth: Optional[Dict[StrictStr, Any]] = None,
121121
_content_type: Optional[StrictStr] = None,
122122
_headers: Optional[Dict[StrictStr, Any]] = None,
123-
_host_index: Annotated[StrictInt, Field(ge=0, le=3)] = 0,
123+
_host_index: Annotated[StrictInt, Field(ge=0, le=4)] = 0,
124124
) -> ApiResponse[None]:
125125
"""Create user
126126
@@ -186,7 +186,7 @@ def create_user_without_preload_content(
186186
_request_auth: Optional[Dict[StrictStr, Any]] = None,
187187
_content_type: Optional[StrictStr] = None,
188188
_headers: Optional[Dict[StrictStr, Any]] = None,
189-
_host_index: Annotated[StrictInt, Field(ge=0, le=3)] = 0,
189+
_host_index: Annotated[StrictInt, Field(ge=0, le=4)] = 0,
190190
) -> RESTResponseType:
191191
"""Create user
192192
@@ -243,6 +243,7 @@ def _create_user_serialize(
243243
) -> RequestSerialized:
244244

245245
_hosts = [
246+
'http://localhost/v2',
246247
'http://petstore.swagger.io/v2',
247248
'http://path-server-test.petstore.local/v2',
248249
'http://{server}.swagger.io:{port}/v2'

0 commit comments

Comments
 (0)