File tree 2 files changed +17
-1
lines changed
2 files changed +17
-1
lines changed Original file line number Diff line number Diff line change @@ -216,7 +216,10 @@ def get_step(
216
216
217
217
for inport in cast (List [CWLObjectType ], step ["in" ]):
218
218
name = "#" + cast (str , inport ["id" ]).split ("#" )[- 1 ].split ("/" )[- 1 ]
219
- extracted ["inputs" ].append (CommentedMap ({"id" : name , "type" : "Any" }))
219
+ inp : CWLObjectType = {"id" : name , "type" : "Any" }
220
+ if "default" in inport :
221
+ inp ["default" ] = inport ["default" ]
222
+ extracted ["inputs" ].append (CommentedMap (inp ))
220
223
inport ["source" ] = name
221
224
if "linkMerge" in inport :
222
225
del inport ["linkMerge" ]
Original file line number Diff line number Diff line change @@ -275,6 +275,19 @@ def test_single_step_packed_subwf_step() -> None:
275
275
)
276
276
277
277
278
+ def test_single_with_step_level_default_value () -> None :
279
+ """Inherit step-level defaults with --single-step."""
280
+ err_code , stdout , stderr = get_main_output (
281
+ [
282
+ "--single-step" ,
283
+ "task2" ,
284
+ get_data ("tests/wf/cache_test_workflow.cwl" ),
285
+ ]
286
+ )
287
+ assert err_code == 0
288
+ assert "two" in stderr
289
+
290
+
278
291
def test_print_targets_embedded_step () -> None :
279
292
"""Confirm that --print-targets works when a Workflow has embedded Processes."""
280
293
err_code , stdout , stderr = get_main_output (
You can’t perform that action at this time.
0 commit comments