apply fixture

This commit is contained in:
JONEMI21 2025-11-10 12:40:17 +00:00
parent 983c112c61
commit b4afab0f16
1 changed files with 3 additions and 3 deletions

View File

@ -4,14 +4,14 @@ from fastapi.testclient import TestClient
from tests.utils import needs_py310
@pytest.fixture(name="client", marks=[needs_py310])
@pytest.fixture(name="client")
def get_client():
from docs_src.query_params.tutorial007_py310 import app
c = TestClient(app)
return c
@needs_py310
def test_foo_needy_very(client: TestClient):
response = client.get("/query/mixed-type-params?query=1&query=2&foo=bar&foo=baz")
assert response.status_code == 200
@ -22,7 +22,7 @@ def test_foo_needy_very(client: TestClient):
"sequence_mapping_int": {"foo": []},
}
@needs_py310
def test_just_string_not_scalar_mapping(client: TestClient):
response = client.get("/query/mixed-type-params?&query=2&foo=1&bar=3&foo=2&foo=baz")
assert response.status_code == 200