Make url_fetch tests work on Windows (#44809)

This commit is contained in:
Nicole C 2024-06-25 03:34:11 -04:00 committed by GitHub
parent 99e3fdb180
commit d8b0df6f5b
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
2 changed files with 3 additions and 5 deletions

View File

@ -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",

View File

@ -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")