Does this type of nested parameterisation exist? #11280
-
I have a number of openapi.yml schemas and want to validate standardization conformance. Essentially something like this (which is ofcourse invalid python): @pytest.fixture(scope="module", params=api.active_openapi_apis(), ids=[i.full_name for i in api.active_openapi_apis()])
def openapi_api(request) -> api.OpenAPI:
return request.param
@pytest.fixture(scope="module", params=[path for api in openapi_api for path in api.paths], ids=[path.name for api in openapi_api for path in api.paths])
def path(request) -> str:
return request.param
def test_path(path: str) -> None:
assert path.startswith("/") |
Beta Was this translation helpful? Give feedback.
Replies: 2 comments
-
covarient parameterization currently is not implemented (where parametersets depend on the value of other parametersets |
Beta Was this translation helpful? Give feedback.
-
Is there a reason you need to use two separate fixtures like this? You could do this if you figure out the combinations in advance, and then either feed it into one fixture as |
Beta Was this translation helpful? Give feedback.
covarient parameterization currently is not implemented (where parametersets depend on the value of other parametersets