Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
20 changes: 8 additions & 12 deletions tests/secondaryfiles/rename-inputs.cwl
Original file line number Diff line number Diff line change
@@ -1,7 +1,5 @@
#!/usr/bin/env cwl-runner
id: InputSecondaryFileConformanceTest
baseCommand:
- ls
class: CommandLineTool
cwlVersion: v1.2
doc: |
Expand All @@ -24,7 +22,6 @@ inputs:
touch secondary_file_test.txt.accessory
```
secondaryFiles:
- .accessory
- |
${
function resolveSecondary(base, secPattern) {
Expand All @@ -37,19 +34,21 @@ inputs:
}
return [{
"class": "File",
"location": self.secondaryFiles[0].location,
"location": inputs.accessory.location,
"basename": resolveSecondary(self.basename, '^.accessory')
}];
}
- id: accessory
type: File


arguments:
- "ls"
- $(inputs.inputWithSecondary.dirname)
- valueFrom: "|"
shellQuote: false
position: 0
- valueFrom: "grep"
position: 1
- valueFrom: "secondary"
position: 2
- "grep"
- "secondary"

outputs:
- id: output_file
Expand All @@ -58,6 +57,3 @@ stdout: result
requirements:
InlineJavascriptRequirement: {}
ShellCommandRequirement: {}
InitialWorkDirRequirement:
listing:
- $(inputs.inputWithSecondary)
3 changes: 3 additions & 0 deletions tests/secondaryfiles/rename-inputs.yml
Original file line number Diff line number Diff line change
@@ -1,3 +1,6 @@
inputWithSecondary:
class: File
location: secondary_file_test.txt
accessory:
class: File
location: secondary_file_test.txt.accessory
2 changes: 1 addition & 1 deletion tests/secondaryfiles/test-index.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@
checksum: sha1$901c3d387a263c57eaed6f24a82517c1fb0e198d
size: 54
location: result
tags: [ inline_javascript, secondary_files, command_line_tool ]
tags: [ inline_javascript, secondary_files, command_line_tool, shell_command ]

- tool: rename-outputs.cwl
doc: Confirm CommandOutputParameter expression can receive a File object
Expand Down