Skip to content

Commit

Permalink
Prevent pytest_generate_tests from polluting preview tests (#6361)
Browse files Browse the repository at this point in the history
  • Loading branch information
silvanocerza authored Nov 20, 2023
1 parent 83c245d commit 365127d
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions conftest.py
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,9 @@ def pytest_addoption(parser):


def pytest_generate_tests(metafunc):
# Ugly hack to avoid polluting preview tests this with unwanted fixtures
if "test/preview" in metafunc.module.__file__ or "test\\preview" in metafunc.module.__file__:
return
# Get selected docstores from CLI arg
document_store_type = metafunc.config.option.document_store_type
selected_doc_stores = [item.strip() for item in document_store_type.split(",")]
Expand Down

0 comments on commit 365127d

Please sign in to comment.