Change file paths for test resource
This commit is contained in:
parent
1f1e7dc63d
commit
607d963450
|
@ -10,11 +10,11 @@ from click.testing import CliRunner
|
||||||
|
|
||||||
from bdfr.__main__ import cli
|
from bdfr.__main__ import cli
|
||||||
|
|
||||||
does_test_config_exist = Path('../test_config.cfg').exists()
|
does_test_config_exist = Path('./tests/test_config.cfg').exists()
|
||||||
|
|
||||||
|
|
||||||
def copy_test_config(run_path: Path):
|
def copy_test_config(run_path: Path):
|
||||||
shutil.copy(Path('../test_config.cfg'), Path(run_path, '../test_config.cfg'))
|
shutil.copy(Path('./tests/test_config.cfg'), Path(run_path, 'test_config.cfg'))
|
||||||
|
|
||||||
|
|
||||||
def create_basic_args_for_archive_runner(test_args: list[str], run_path: Path):
|
def create_basic_args_for_archive_runner(test_args: list[str], run_path: Path):
|
||||||
|
@ -23,7 +23,7 @@ def create_basic_args_for_archive_runner(test_args: list[str], run_path: Path):
|
||||||
'archive',
|
'archive',
|
||||||
str(run_path),
|
str(run_path),
|
||||||
'-v',
|
'-v',
|
||||||
'--config', str(Path(run_path, '../test_config.cfg')),
|
'--config', str(Path(run_path, 'test_config.cfg')),
|
||||||
'--log', str(Path(run_path, 'test_log.txt')),
|
'--log', str(Path(run_path, 'test_log.txt')),
|
||||||
] + test_args
|
] + test_args
|
||||||
return out
|
return out
|
||||||
|
|
|
@ -9,11 +9,11 @@ from click.testing import CliRunner
|
||||||
|
|
||||||
from bdfr.__main__ import cli
|
from bdfr.__main__ import cli
|
||||||
|
|
||||||
does_test_config_exist = Path('../test_config.cfg').exists()
|
does_test_config_exist = Path('./tests/test_config.cfg').exists()
|
||||||
|
|
||||||
|
|
||||||
def copy_test_config(run_path: Path):
|
def copy_test_config(run_path: Path):
|
||||||
shutil.copy(Path('../test_config.cfg'), Path(run_path, '../test_config.cfg'))
|
shutil.copy(Path('./tests/test_config.cfg'), Path(run_path, 'test_config.cfg'))
|
||||||
|
|
||||||
|
|
||||||
def create_basic_args_for_cloner_runner(test_args: list[str], tmp_path: Path):
|
def create_basic_args_for_cloner_runner(test_args: list[str], tmp_path: Path):
|
||||||
|
|
|
@ -9,11 +9,11 @@ from click.testing import CliRunner
|
||||||
|
|
||||||
from bdfr.__main__ import cli
|
from bdfr.__main__ import cli
|
||||||
|
|
||||||
does_test_config_exist = Path('../test_config.cfg').exists()
|
does_test_config_exist = Path('./tests/test_config.cfg').exists()
|
||||||
|
|
||||||
|
|
||||||
def copy_test_config(run_path: Path):
|
def copy_test_config(run_path: Path):
|
||||||
shutil.copy(Path('../test_config.cfg'), Path(run_path, '../test_config.cfg'))
|
shutil.copy(Path('./tests/test_config.cfg'), Path(run_path, './test_config.cfg'))
|
||||||
|
|
||||||
|
|
||||||
def create_basic_args_for_download_runner(test_args: list[str], run_path: Path):
|
def create_basic_args_for_download_runner(test_args: list[str], run_path: Path):
|
||||||
|
@ -21,7 +21,7 @@ def create_basic_args_for_download_runner(test_args: list[str], run_path: Path):
|
||||||
out = [
|
out = [
|
||||||
'download', str(run_path),
|
'download', str(run_path),
|
||||||
'-v',
|
'-v',
|
||||||
'--config', str(Path(run_path, '../test_config.cfg')),
|
'--config', str(Path(run_path, './test_config.cfg')),
|
||||||
'--log', str(Path(run_path, 'test_log.txt')),
|
'--log', str(Path(run_path, 'test_log.txt')),
|
||||||
] + test_args
|
] + test_args
|
||||||
return out
|
return out
|
||||||
|
|
Loading…
Reference in a new issue