From 747aeb9a494e71d69163c27cdaee958468dfa80e Mon Sep 17 00:00:00 2001 From: Miguel Grinberg Date: Thu, 25 Apr 2024 11:01:43 +0100 Subject: [PATCH] explicit use of fixture decorator (#1783) (cherry picked from commit ff406e9a09ee0dc39dc75693c86f80de43540b1b) --- .../test_examples/_async/test_parent_child.py | 4 ++-- .../test_integration/test_examples/_sync/test_parent_child.py | 3 +-- 2 files changed, 3 insertions(+), 4 deletions(-) diff --git a/tests/test_integration/test_examples/_async/test_parent_child.py b/tests/test_integration/test_examples/_async/test_parent_child.py index 916fa728..667ffd0b 100644 --- a/tests/test_integration/test_examples/_async/test_parent_child.py +++ b/tests/test_integration/test_examples/_async/test_parent_child.py @@ -18,7 +18,7 @@ from datetime import datetime import pytest -from pytest_asyncio import fixture +import pytest_asyncio from elasticsearch_dsl import Q @@ -41,7 +41,7 @@ ) -@fixture +@pytest_asyncio.fixture async def question(async_write_client): await setup() assert await async_write_client.indices.exists_template(name="base") diff --git a/tests/test_integration/test_examples/_sync/test_parent_child.py b/tests/test_integration/test_examples/_sync/test_parent_child.py index cda90974..4c82cdd7 100644 --- a/tests/test_integration/test_examples/_sync/test_parent_child.py +++ b/tests/test_integration/test_examples/_sync/test_parent_child.py @@ -18,7 +18,6 @@ from datetime import datetime import pytest -from pytest import fixture from elasticsearch_dsl import Q @@ -41,7 +40,7 @@ ) -@fixture +@pytest.fixture def question(write_client): setup() assert write_client.indices.exists_template(name="base")