diff --git a/lib/galaxy_test/api/test_workflow_build_module.py b/lib/galaxy_test/api/test_workflow_build_module.py
new file mode 100644
index 000000000000..72858018643a
--- /dev/null
+++ b/lib/galaxy_test/api/test_workflow_build_module.py
@@ -0,0 +1,19 @@
+from galaxy_test.base.populators import (
+ skip_without_tool,
+ WorkflowPopulator,
+)
+from ._framework import ApiTestCase
+
+
+class TestBuildWorkflowModule(ApiTestCase):
+
+ def setUp(self):
+ super().setUp()
+ self.workflow_populator = WorkflowPopulator(self.galaxy_interactor)
+
+ @skip_without_tool("select_from_url")
+ def test_build_module_filter_dynamic_select(self):
+ # Verify that filtering on parameters that depend on parameter and validators works
+ # fine in workflow building mode.
+ module = self.workflow_populator.build_module(tool_id="select_from_url")
+ assert not module["errors"], module["errors"]
diff --git a/lib/galaxy_test/base/populators.py b/lib/galaxy_test/base/populators.py
index 014880ebd1e6..e484c1ed680a 100644
--- a/lib/galaxy_test/base/populators.py
+++ b/lib/galaxy_test/base/populators.py
@@ -2298,6 +2298,20 @@ def import_tool(self, tool) -> Dict[str, Any]:
assert upload_response.status_code == 200, upload_response
return upload_response.json()
+ def build_module(
+ self, tool_id: Optional[str] = None, workflow_id: Optional[str] = None, inputs: Optional[Dict[str, Any]] = None
+ ):
+ payload = {"inputs": inputs or {}}
+ if tool_id:
+ payload["content_id"] = tool_id
+ payload["type"] = "tool"
+ if workflow_id:
+ payload["content_id"] = workflow_id
+ payload["type"] = "subworkflow"
+ response = self._post("workflows/build_module", data=payload, json=True)
+ assert response.status_code == 200, response
+ return response.json()
+
def _import_tool_response(self, tool) -> Response:
using_requirement("admin")
tool_str = json.dumps(tool, indent=4)
diff --git a/test/functional/tools/select_from_url.xml b/test/functional/tools/select_from_url.xml
index 60a712e74631..488055677e85 100644
--- a/test/functional/tools/select_from_url.xml
+++ b/test/functional/tools/select_from_url.xml
@@ -10,6 +10,13 @@ echo '$url_param_value_header_and_body' > '$param_value_header_and_body'
+
+
+
+
+
+
+