From 8cad6f15cc65ed9675090e556483232efe1a544c Mon Sep 17 00:00:00 2001 From: Peter Amstutz Date: Thu, 15 Sep 2016 15:03:26 -0400 Subject: [PATCH] Add test for requirements/hints on workflow steps. --- v1.0/conformance_test_v1.0.yaml | 10 ++++++++++ v1.0/v1.0/cat5-tool.cwl | 4 +++- v1.0/v1.0/env-wf1.cwl | 3 +-- v1.0/v1.0/env-wf2.cwl | 3 +-- v1.0/v1.0/env-wf3.cwl | 22 ++++++++++++++++++++++ 5 files changed, 37 insertions(+), 5 deletions(-) create mode 100644 v1.0/v1.0/env-wf3.cwl diff --git a/v1.0/conformance_test_v1.0.yaml b/v1.0/conformance_test_v1.0.yaml index 21377bb14..21eabe0b4 100644 --- a/v1.0/conformance_test_v1.0.yaml +++ b/v1.0/conformance_test_v1.0.yaml @@ -287,6 +287,16 @@ tool: v1.0/env-wf2.cwl doc: Test requirements override hints +- job: v1.0/env-job.json + output: + out: + class: File + checksum: sha1$cdc1e84968261d6a7575b5305945471f8be199b6 + location: out + size: 9 + tool: v1.0/env-wf3.cwl + doc: Test requirements on workflow steps + - job: v1.0/empty.json output: {count_output: 16} tool: v1.0/count-lines9-wf.cwl diff --git a/v1.0/v1.0/cat5-tool.cwl b/v1.0/v1.0/cat5-tool.cwl index e5ae681cc..c106cd602 100755 --- a/v1.0/v1.0/cat5-tool.cwl +++ b/v1.0/v1.0/cat5-tool.cwl @@ -1,11 +1,13 @@ #!/usr/bin/env cwl-runner +$namespaces: + ex: http://example.com/ cwlVersion: v1.0 class: CommandLineTool doc: "Print the contents of a file to stdout using 'cat' running in a docker container." hints: DockerRequirement: dockerPull: "debian:wheezy" - BlibberBlubberFakeRequirement: + ex:BlibberBlubberFakeRequirement: fakeField: fraggleFroogle inputs: file1: diff --git a/v1.0/v1.0/env-wf1.cwl b/v1.0/v1.0/env-wf1.cwl index f5cd51715..9a8487f2a 100644 --- a/v1.0/v1.0/env-wf1.cwl +++ b/v1.0/v1.0/env-wf1.cwl @@ -11,8 +11,7 @@ outputs: outputSource: step1/out requirements: - - class: SubworkflowFeatureRequirement - - class: EnvVarRequirement + EnvVarRequirement: envDef: TEST_ENV: override diff --git a/v1.0/v1.0/env-wf2.cwl b/v1.0/v1.0/env-wf2.cwl index 8a89b5796..2c43e5b65 100644 --- a/v1.0/v1.0/env-wf2.cwl +++ b/v1.0/v1.0/env-wf2.cwl @@ -11,8 +11,7 @@ outputs: outputSource: step1/out requirements: - - class: SubworkflowFeatureRequirement - - class: EnvVarRequirement + EnvVarRequirement: envDef: TEST_ENV: override diff --git a/v1.0/v1.0/env-wf3.cwl b/v1.0/v1.0/env-wf3.cwl new file mode 100644 index 000000000..4fd2dc3b5 --- /dev/null +++ b/v1.0/v1.0/env-wf3.cwl @@ -0,0 +1,22 @@ +#!/usr/bin/env cwl-runner +class: Workflow +cwlVersion: v1.0 + +inputs: + in: string + +outputs: + out: + type: File + outputSource: step1/out + +steps: + step1: + run: env-tool2.cwl + requirements: + EnvVarRequirement: + envDef: + TEST_ENV: override + in: + in: in + out: [out]