diff --git a/lib/galaxy/tool_util/cwl/util.py b/lib/galaxy/tool_util/cwl/util.py index e22d96737464..3051ba669171 100644 --- a/lib/galaxy/tool_util/cwl/util.py +++ b/lib/galaxy/tool_util/cwl/util.py @@ -599,7 +599,12 @@ def dir_listing(dir_path): if extra_file_class == "File": ec = get_dataset(output_metadata, filename=path) ec["basename"] = ec_basename - ec_properties = output_properties(pseudo_location=pseudo_location, **ec) + download_url = ( + output_metadata["download_url"] + f"?filename={urllib.parse.quote_plus(path)}" + ) + ec_properties = output_properties( + pseudo_location=pseudo_location, download_url=download_url, **ec + ) elif extra_file_class == "Directory": ec_properties = {} ec_properties["class"] = "Directory" diff --git a/lib/galaxy_test/base/populators.py b/lib/galaxy_test/base/populators.py index ca8c54b7fc80..8c7f87919055 100644 --- a/lib/galaxy_test/base/populators.py +++ b/lib/galaxy_test/base/populators.py @@ -267,6 +267,10 @@ def conformance_tests_gen(directory, filename="conformance_tests.yaml"): def output_to_disk(output, download_folder): if isinstance(output, dict): + if "secondaryFiles" in output: + output["secondaryFiles"] = [ + output_to_disk(secondary, download_folder=download_folder) for secondary in output["secondaryFiles"] + ] if "basename" in output: download_path = os.path.join(download_folder, output["basename"]) download_to_file(output["location"], download_path)