Skip to content

Commit f79ac07

Browse files
Chore: Fix flakey test by clearing cache to pick up changes
Signed-off-by: Themis Valtinos <73662635+themisvaltinos@users.noreply.github.com>
1 parent 08c1375 commit f79ac07

File tree

1 file changed

+5
-0
lines changed

1 file changed

+5
-0
lines changed

tests/dbt/cli/test_run.py

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,7 @@
11
import typing as t
22
import pytest
33
from pathlib import Path
4+
import shutil
45
from click.testing import Result
56
import time_machine
67
from sqlmesh_dbt.operations import create
@@ -71,6 +72,10 @@ def test_run_with_changes_and_full_refresh(
7172
if partial_parse_file.exists():
7273
partial_parse_file.unlink()
7374

75+
cache_dir = project_path / ".cache"
76+
if cache_dir.exists():
77+
shutil.rmtree(cache_dir)
78+
7479
# run with --full-refresh. this should:
7580
# - fully refresh model_a (pick up the new records from external_table)
7681
# - deploy the local change to model_b (introducing the 'changed' column)

0 commit comments

Comments
 (0)