1
0
Fork 0
mirror of https://github.com/correl/openapi-core.git synced 2025-04-03 17:00:18 -09:00
openapi-core/openapi_core/testing/responses.py
2020-01-17 14:52:26 +00:00

13 lines
376 B
Python

"""OpenAPI core testing responses module"""
from openapi_core.validation.response.datatypes import OpenAPIResponse
class MockResponseFactory(object):
@classmethod
def create(cls, data, status_code=200, mimetype='application/json'):
return OpenAPIResponse(
data=data,
status_code=status_code,
mimetype=mimetype,
)