You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

15 lines
424 B

import pytest
import shutil
from pathlib import Path
def fill_mock_backup_dir(rootdir: Path, target_dir: Path):
for property_file in rootdir.glob("*.properties"):
shutil.copy2(property_file, target_dir / property_file.name)
for other_file in filter(
lambda path: path.suffix != ".properties", rootdir.glob("*")
):
dest = target_dir / other_file.name
dest.touch(exist_ok=True)