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
13 changes: 12 additions & 1 deletion conformance_tests.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -3570,6 +3570,17 @@
and capture the output correctly.
tags: [ shell_command, command_line_tool ]

- label: js-input-record
# The output does not have the last \n due to the -n passed to echo
output: {
"out": "JS\nwith\nrecord"
}
tool: tests/js-input-record.cwl
job: tests/js-input-record.json
doc: |
A test case for JS with an input record.
tags: [ inline_javascript, command_line_tool ]

- tool: tests/schemadef_types_with_import-wf.cwl
job: tests/schemadef_types_with_import-job.json
output: {
Expand All @@ -3579,4 +3590,4 @@
doc: >-
Test SchemaDefRequirement with a workflow, with the `$import` under types.
It is similar to schemadef-wf, but the `$import` is different.
tags: [ workflow, schema_def ]
tags: [ workflow, schema_def ]
33 changes: 33 additions & 0 deletions tests/js-input-record.cwl
Original file line number Diff line number Diff line change
@@ -0,0 +1,33 @@
cwlVersion: v1.0

class: CommandLineTool

requirements:
- class: InlineJavascriptRequirement

baseCommand: ['echo']

inputs:
message:
type:
type: record
name: message_object
fields:
text:
type: string
inputBinding:
position: 1
newlines:
type: boolean?
inputBinding:
position: 0
prefix: -n

outputs:
out:
type: string
outputBinding:
glob: output.txt
loadContents: true
outputEval: $(self[0].contents)
stdout: output.txt
7 changes: 7 additions & 0 deletions tests/js-input-record.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
{
"message": {
"text": "JS\nwith\nrecord",
"newlines": true
}
}