test(fixtures): allow the active test temporary directory

This commit is contained in:
2026-10-30 04:31:38 -03:00
parent 3151b0c7dd
commit 5fb2ba6df8
2 changed files with 3 additions and 1 deletions
+2 -1
View File
@@ -16,7 +16,8 @@ with (root / "platform-calls.jsonl").open("a") as log:
def fixture_path(value):
path = pathlib.Path(value).resolve()
if not path.is_relative_to(root):
active_test = pathlib.Path(os.environ["BATS_TEST_TMPDIR"]).resolve()
if not (path.is_relative_to(root) or path.is_relative_to(active_test)):
sys.exit(f"Fixture refused path outside the suite: {path}")
return path