summaryrefslogtreecommitdiff
path: root/tests/sources/generic
diff options
context:
space:
mode:
Diffstat (limited to 'tests/sources/generic')
-rw-r--r--tests/sources/generic/build_checkout.py2
-rw-r--r--tests/sources/generic/fetch.py2
-rw-r--r--tests/sources/generic/track.py14
-rw-r--r--tests/sources/generic/workspace.py4
4 files changed, 11 insertions, 11 deletions
diff --git a/tests/sources/generic/build_checkout.py b/tests/sources/generic/build_checkout.py
index f2dee6c60..e113b40cb 100644
--- a/tests/sources/generic/build_checkout.py
+++ b/tests/sources/generic/build_checkout.py
@@ -46,7 +46,7 @@ def strict_args(args, strict):
@pytest.mark.parametrize("strict,kind", fetch_build_checkout_combos)
def test_fetch_build_checkout(cli, tmpdir, datafiles, strict, kind):
checkout = os.path.join(cli.directory, 'checkout')
- project = os.path.join(datafiles.dirname, datafiles.basename)
+ project = str(datafiles)
dev_files_path = os.path.join(project, 'files', 'dev-files')
element_path = os.path.join(project, 'elements')
element_name = 'build-test-{}.bst'.format(kind)
diff --git a/tests/sources/generic/fetch.py b/tests/sources/generic/fetch.py
index 3c7a28182..f5931f8f1 100644
--- a/tests/sources/generic/fetch.py
+++ b/tests/sources/generic/fetch.py
@@ -37,7 +37,7 @@ DATA_DIR = os.path.join(TOP_DIR, 'project')
@pytest.mark.datafiles(DATA_DIR)
@pytest.mark.parametrize("kind", [(kind) for kind in ALL_REPO_KINDS])
def test_fetch(cli, tmpdir, datafiles, kind):
- project = os.path.join(datafiles.dirname, datafiles.basename)
+ project = str(datafiles)
bin_files_path = os.path.join(project, 'files', 'bin-files')
element_path = os.path.join(project, 'elements')
element_name = 'fetch-test-{}.bst'.format(kind)
diff --git a/tests/sources/generic/track.py b/tests/sources/generic/track.py
index 76956fcdb..4726a453e 100644
--- a/tests/sources/generic/track.py
+++ b/tests/sources/generic/track.py
@@ -52,7 +52,7 @@ def generate_element(repo, element_path, dep_name=None):
@pytest.mark.parametrize("ref_storage", [('inline'), ('project.refs')])
@pytest.mark.parametrize("kind", [(kind) for kind in ALL_REPO_KINDS])
def test_track(cli, tmpdir, datafiles, ref_storage, kind):
- project = os.path.join(datafiles.dirname, datafiles.basename)
+ project = str(datafiles)
dev_files_path = os.path.join(project, 'files', 'dev-files')
element_path = os.path.join(project, 'elements')
element_name = 'track-test-{}.bst'.format(kind)
@@ -112,7 +112,7 @@ def test_track(cli, tmpdir, datafiles, ref_storage, kind):
@pytest.mark.parametrize("amount", [(1), (10)])
@pytest.mark.parametrize("kind", [(kind) for kind in ALL_REPO_KINDS])
def test_track_recurse(cli, tmpdir, datafiles, kind, amount):
- project = os.path.join(datafiles.dirname, datafiles.basename)
+ project = str(datafiles)
dev_files_path = os.path.join(project, 'files', 'dev-files')
element_path = os.path.join(project, 'elements')
@@ -176,7 +176,7 @@ def test_track_recurse(cli, tmpdir, datafiles, kind, amount):
@pytest.mark.datafiles(DATA_DIR)
@pytest.mark.parametrize("kind", [(kind) for kind in ALL_REPO_KINDS])
def test_track_recurse_except(cli, tmpdir, datafiles, kind):
- project = os.path.join(datafiles.dirname, datafiles.basename)
+ project = str(datafiles)
dev_files_path = os.path.join(project, 'files', 'dev-files')
element_path = os.path.join(project, 'elements')
element_dep_name = 'track-test-dep-{}.bst'.format(kind)
@@ -223,7 +223,7 @@ def test_track_recurse_except(cli, tmpdir, datafiles, kind):
@pytest.mark.parametrize("ref_storage", [('inline'), ('project.refs')])
@pytest.mark.parametrize("kind", [(kind) for kind in ALL_REPO_KINDS])
def test_cross_junction(cli, tmpdir, datafiles, ref_storage, kind):
- project = os.path.join(datafiles.dirname, datafiles.basename)
+ project = str(datafiles)
subproject_path = os.path.join(project, 'files', 'sub-project')
junction_path = os.path.join(project, 'elements', 'junction.bst')
etc_files = os.path.join(subproject_path, 'files', 'etc-files')
@@ -266,7 +266,7 @@ def test_cross_junction(cli, tmpdir, datafiles, ref_storage, kind):
@pytest.mark.parametrize("ref_storage", [('inline'), ('project.refs')])
@pytest.mark.parametrize("kind", [(kind) for kind in ALL_REPO_KINDS])
def test_track_include(cli, tmpdir, datafiles, ref_storage, kind):
- project = os.path.join(datafiles.dirname, datafiles.basename)
+ project = str(datafiles)
dev_files_path = os.path.join(project, 'files', 'dev-files')
element_path = os.path.join(project, 'elements')
element_name = 'track-test-{}.bst'.format(kind)
@@ -329,7 +329,7 @@ def test_track_include(cli, tmpdir, datafiles, ref_storage, kind):
@pytest.mark.parametrize("ref_storage", [('inline'), ('project.refs')])
@pytest.mark.parametrize("kind", [(kind) for kind in ALL_REPO_KINDS])
def test_track_include_junction(cli, tmpdir, datafiles, ref_storage, kind):
- project = os.path.join(datafiles.dirname, datafiles.basename)
+ project = str(datafiles)
dev_files_path = os.path.join(project, 'files', 'dev-files')
element_path = os.path.join(project, 'elements')
element_name = 'track-test-{}.bst'.format(kind)
@@ -398,7 +398,7 @@ def test_track_include_junction(cli, tmpdir, datafiles, ref_storage, kind):
@pytest.mark.parametrize("ref_storage", [('inline'), ('project.refs')])
@pytest.mark.parametrize("kind", [(kind) for kind in ALL_REPO_KINDS])
def test_track_junction_included(cli, tmpdir, datafiles, ref_storage, kind):
- project = os.path.join(datafiles.dirname, datafiles.basename)
+ project = str(datafiles)
element_path = os.path.join(project, 'elements')
subproject_path = os.path.join(project, 'files', 'sub-project')
junction_path = os.path.join(element_path, 'junction.bst')
diff --git a/tests/sources/generic/workspace.py b/tests/sources/generic/workspace.py
index 552981a4f..ad115c1ba 100644
--- a/tests/sources/generic/workspace.py
+++ b/tests/sources/generic/workspace.py
@@ -40,9 +40,9 @@ class WorkspaceCreator():
self.datafiles = datafiles
if not project_path:
- project_path = os.path.join(datafiles.dirname, datafiles.basename)
+ project_path = str(datafiles)
else:
- shutil.copytree(os.path.join(datafiles.dirname, datafiles.basename), project_path)
+ shutil.copytree(str(datafiles), project_path)
self.project_path = project_path
self.bin_files_path = os.path.join(project_path, 'files', 'bin-files')