Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Use tmpdir_factory instead of tmp_path_factory to see if it helps fix flaky file-based test #483

Merged
merged 2 commits into from
Dec 4, 2024
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions tests/conftest.py
Original file line number Diff line number Diff line change
Expand Up @@ -58,7 +58,7 @@ def bv_server_process(profile_type):
# The profile dictionary, used to write out profiles.yml
# dbt will supply a unique schema per test, so we do not specify 'schema' here
@pytest.fixture(scope="session")
def dbt_profile_target(profile_type, bv_server_process, tmp_path_factory):
def dbt_profile_target(profile_type, bv_server_process, tmpdir_factory):
profile = {"type": "duckdb", "threads": 4}

if profile_type == "buenavista":
Expand All @@ -69,7 +69,7 @@ def dbt_profile_target(profile_type, bv_server_process, tmp_path_factory):
"user": "test",
}
elif profile_type == "file":
profile["path"] = str(tmp_path_factory.getbasetemp() / "tmp.db")
profile["path"] = str(tmpdir_factory.mktemp("dbs") / "tmp.db")
elif profile_type == "md":
# Test against MotherDuck
if MOTHERDUCK_TOKEN not in os.environ and MOTHERDUCK_TOKEN.lower() not in os.environ:
Expand Down
Loading