diff options
author | Nicole C <48625123+nicolecheetham@users.noreply.github.com> | 2024-06-25 03:34:11 -0400 |
---|---|---|
committer | GitHub <noreply@github.com> | 2024-06-25 07:34:11 +0000 |
commit | d8b0df6f5bc44f830f1da1cf35c15462abda5cd4 (patch) | |
tree | 16bea6a2ddc115e66867a019bc7d47c8f834853e | |
parent | 99e3fdb18076cb51eefc51084ce93006ec849933 (diff) | |
download | spack-d8b0df6f5bc44f830f1da1cf35c15462abda5cd4.tar.gz spack-d8b0df6f5bc44f830f1da1cf35c15462abda5cd4.tar.bz2 spack-d8b0df6f5bc44f830f1da1cf35c15462abda5cd4.tar.xz spack-d8b0df6f5bc44f830f1da1cf35c15462abda5cd4.zip |
Make url_fetch tests work on Windows (#44809)
-rw-r--r-- | lib/spack/spack/test/url_fetch.py | 3 | ||||
-rw-r--r-- | var/spack/repos/builtin.mock/packages/url-list-test/package.py | 5 |
2 files changed, 3 insertions, 5 deletions
diff --git a/lib/spack/spack/test/url_fetch.py b/lib/spack/spack/test/url_fetch.py index 6dd548d858..dadac0944e 100644 --- a/lib/spack/spack/test/url_fetch.py +++ b/lib/spack/spack/test/url_fetch.py @@ -173,8 +173,6 @@ def test_fetch( assert "echo Building..." in contents -# TODO-27021 -@pytest.mark.not_on_windows("Not supported on Windows (yet)") @pytest.mark.parametrize( "spec,url,digest", [ @@ -205,7 +203,6 @@ def test_from_list_url(mock_packages, config, spec, url, digest, _fetch_method): assert fetch_strategy.extra_options == {"timeout": 60} -@pytest.mark.not_on_windows("Not supported on Windows (yet)") @pytest.mark.parametrize("_fetch_method", ["curl", "urllib"]) @pytest.mark.parametrize( "requested_version,tarball,digest", diff --git a/var/spack/repos/builtin.mock/packages/url-list-test/package.py b/var/spack/repos/builtin.mock/packages/url-list-test/package.py index 0beae47abc..416451293f 100644 --- a/var/spack/repos/builtin.mock/packages/url-list-test/package.py +++ b/var/spack/repos/builtin.mock/packages/url-list-test/package.py @@ -5,6 +5,7 @@ import spack.paths from spack.package import * +from spack.util.url import path_to_file_url class UrlListTest(Package): @@ -13,8 +14,8 @@ class UrlListTest(Package): homepage = "http://www.url-list-example.com" web_data_path = join_path(spack.paths.test_path, "data", "web") - url = "file://" + web_data_path + "/foo-0.0.0.tar.gz" - list_url = "file://" + web_data_path + "/index.html" + url = path_to_file_url(join_path(spack.paths.test_path, "data", "web") + "/foo-0.0.0.tar.gz") + list_url = path_to_file_url(join_path(spack.paths.test_path, "data", "web") + "/index.html") list_depth = 3 version("0.0.0", md5="00000000000000000000000000000000") |