diff options
author | Daniel Baumann <daniel.baumann@progress-linux.org> | 2024-04-29 04:26:28 +0000 |
---|---|---|
committer | Daniel Baumann <daniel.baumann@progress-linux.org> | 2024-04-29 04:26:28 +0000 |
commit | bbbeb2d07d4f7fd0191032c219b40565fd83454f (patch) | |
tree | 3c08f1e09ed89a004867762ab40f3b610f6c0fa1 /tests/conftest.py | |
parent | Initial commit. (diff) | |
download | flit-bbbeb2d07d4f7fd0191032c219b40565fd83454f.tar.xz flit-bbbeb2d07d4f7fd0191032c219b40565fd83454f.zip |
Adding upstream version 3.8.0.upstream/3.8.0upstream
Signed-off-by: Daniel Baumann <daniel.baumann@progress-linux.org>
Diffstat (limited to 'tests/conftest.py')
-rw-r--r-- | tests/conftest.py | 15 |
1 files changed, 15 insertions, 0 deletions
diff --git a/tests/conftest.py b/tests/conftest.py new file mode 100644 index 0000000..4c5ecef --- /dev/null +++ b/tests/conftest.py @@ -0,0 +1,15 @@ +from pathlib import Path +import pytest +from shutil import copytree + +samples_dir = Path(__file__).parent / 'samples' + +@pytest.fixture +def copy_sample(tmp_path): + """Copy a subdirectory from the samples dir to a temp dir""" + def copy(dirname): + dst = tmp_path / dirname + copytree(str(samples_dir / dirname), str(dst)) + return dst + + return copy |