openapi-core/tests/unit/test_operations.py
2017-09-21 12:51:37 +01:00

20 lines
523 B
Python

import mock
import pytest
from openapi_core.operations import Operation
class TestSchemas(object):
@pytest.fixture
def oepration(self):
parameters = {
'parameter_1': mock.sentinel.parameter_1,
'parameter_2': mock.sentinel.parameter_2,
}
return Operation('get', '/path', parameters=parameters)
@property
def test_iteritems(self, oepration):
for name in oepration.parameters.keys():
assert oepration[name] == oepration.parameters[name]