Files
pyflowx/tests/conftest.py
T
zhou 6f64d9d6dc
Release / Build Artifacts (push) Has been skipped
Release / Publish to PyPI (push) Has been skipped
Release / Publish Release (push) Has been skipped
Release / Pre-release Check (push) Failing after 31s
bump version to 0.2.3
2026-06-26 07:43:56 +08:00

17 lines
418 B
Python

from __future__ import annotations
from pathlib import Path
import pytest
@pytest.fixture(autouse=True)
def packtool_tmp_workdir(tmp_path: Path, monkeypatch: pytest.MonkeyPatch) -> None:
"""自动切换到临时工作目录,防止测试污染项目根目录.
Args:
tmp_path: pytest 提供的临时目录
monkeypatch: pytest 的 monkeypatch 工具
"""
monkeypatch.chdir(tmp_path)