[ARVADOS] updated: dd0f2323bd5fbcef6a3921c45d6e3025a77d2e35
git at public.curoverse.com
git at public.curoverse.com
Wed Oct 1 14:29:36 EDT 2014
Summary of changes:
.../pipeline_instances_controller_test.rb | 16 +++++++++++++
services/api/test/fixtures/pipeline_instances.yml | 13 ++++++----
services/api/test/fixtures/pipeline_templates.yml | 28 ++++++++++++----------
3 files changed, 40 insertions(+), 17 deletions(-)
via dd0f2323bd5fbcef6a3921c45d6e3025a77d2e35 (commit)
from 5233f1d185706095d2f045b8431781c9a421ee16 (commit)
Those revisions listed above that are new to this repository have
not appeared on any other notification email; so we list those
revisions in full, below.
commit dd0f2323bd5fbcef6a3921c45d6e3025a77d2e35
Author: Tim Pierce <twp at curoverse.com>
Date: Wed Oct 1 14:28:38 2014 -0400
4000: tighten up functional test
Updated the test to ensure that a copied pipeline instance actually has
the expected script_parameters from both the source instance and source
template, respectively.
diff --git a/apps/workbench/test/functional/pipeline_instances_controller_test.rb b/apps/workbench/test/functional/pipeline_instances_controller_test.rb
index 69d0664..f3e1068 100644
--- a/apps/workbench/test/functional/pipeline_instances_controller_test.rb
+++ b/apps/workbench/test/functional/pipeline_instances_controller_test.rb
@@ -121,7 +121,23 @@ class PipelineInstancesControllerTest < ActionController::TestCase
session_for(:active))
assert_response 302
assert_not_nil assigns(:object)
+
+ # Component 'foo' has script parameters only in the pipeline instance.
+ # Component 'bar' is present only in the pipeline_template.
+ # Test that the copied pipeline instance includes parameters for
+ # component 'foo' from the source instance, and parameters for
+ # component 'bar' from the source template.
+ #
assert_not_nil assigns(:object).components[:foo]
+ foo = assigns(:object).components[:foo]
+ assert_not_nil foo[:script_parameters]
+ assert_not_nil foo[:script_parameters][:input]
+ assert_equal 'foo instance input', foo[:script_parameters][:input][:title]
+
assert_not_nil assigns(:object).components[:bar]
+ bar = assigns(:object).components[:bar]
+ assert_not_nil bar[:script_parameters]
+ assert_not_nil bar[:script_parameters][:input]
+ assert_equal 'bar template input', bar[:script_parameters][:input][:title]
end
end
diff --git a/services/api/test/fixtures/pipeline_instances.yml b/services/api/test/fixtures/pipeline_instances.yml
index 2ccfab7..a3d372b 100644
--- a/services/api/test/fixtures/pipeline_instances.yml
+++ b/services/api/test/fixtures/pipeline_instances.yml
@@ -135,8 +135,11 @@ pipeline_with_newer_template:
pipeline_template_uuid: zzzzz-p5p6p-vq4wuvy84xvaq2r
created_at: 2014-09-15 12:00:00
components:
- foo:
- script: foo
- script_version: master
- script_parameters:
- input: foo_input
+ foo:
+ script: foo
+ script_version: master
+ script_parameters:
+ input:
+ required: true
+ dataclass: Collection
+ title: foo instance input
diff --git a/services/api/test/fixtures/pipeline_templates.yml b/services/api/test/fixtures/pipeline_templates.yml
index bb825cf..31ebb97 100644
--- a/services/api/test/fixtures/pipeline_templates.yml
+++ b/services/api/test/fixtures/pipeline_templates.yml
@@ -89,15 +89,19 @@ new_pipeline_template:
created_at: 2014-09-14 12:00:00
modified_at: 2014-09-16 12:00:00
components:
- foo:
- script: foo
- script_version: master
- script_parameters: {}
- bar:
- script: bar
- script_version: master
- script_parameters:
- input:
- required: true
- dataclass: Collection
- title: "bar input"
+ foo:
+ script: foo
+ script_version: master
+ script_parameters:
+ input:
+ required: true
+ dataclass: Collection
+ title: foo template input
+ bar:
+ script: bar
+ script_version: master
+ script_parameters:
+ input:
+ required: true
+ dataclass: Collection
+ title: bar template input
-----------------------------------------------------------------------
hooks/post-receive
--
More information about the arvados-commits
mailing list