forked from galaxyproject/galaxy
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Parameter specification reference testing - conditionals with selects.
- Loading branch information
Showing
4 changed files
with
143 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
85 changes: 85 additions & 0 deletions
85
test/functional/tools/parameters/gx_conditional_select.xml
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,85 @@ | ||
<tool id="gx_conditional_select" name="gx_conditional_select" version="1.0.0"> | ||
<macros> | ||
<import>macros.xml</import> | ||
</macros> | ||
<expand macro="common_conditional_tags" /> | ||
<inputs> | ||
<conditional name="conditional_parameter"> | ||
<param name="test_parameter" type="select"> | ||
<option value="a">A</option> | ||
<option value="b">B</option> | ||
<option value="c">C</option> | ||
</param> | ||
<when value="a"> | ||
<param name="integer_parameter" type="integer" value="1" /> | ||
</when> | ||
<when value="b"> | ||
<param name="boolean_parameter" type="boolean" /> | ||
</when> | ||
<when value="c"> | ||
<param name="color_parameter" type="color" value="#aabbcc" /> | ||
</when> | ||
</conditional> | ||
</inputs> | ||
<tests> | ||
<test> | ||
<expand macro="assert_output"> | ||
<has_line line="test: a" /> | ||
</expand> | ||
<expand macro="assert_inputs_json"> | ||
<has_json_property_with_value property="test_parameter" value=""a"" /> | ||
<has_json_property_with_value property="integer_parameter" value="1" /> | ||
</expand> | ||
</test> | ||
<test> | ||
<conditional name="conditional_parameter"> | ||
<param name="test_parameter" value="b" /> | ||
</conditional> | ||
<expand macro="assert_output"> | ||
<has_line line="test: b" /> | ||
</expand> | ||
<expand macro="assert_inputs_json"> | ||
<has_json_property_with_value property="test_parameter" value=""b"" /> | ||
<has_json_property_with_value property="boolean_parameter" value="false" /> | ||
</expand> | ||
</test> | ||
<test> | ||
<conditional name="conditional_parameter"> | ||
<param name="test_parameter" value="a" /> | ||
</conditional> | ||
<expand macro="assert_output"> | ||
<has_line line="test: a" /> | ||
</expand> | ||
<expand macro="assert_inputs_json"> | ||
<has_json_property_with_value property="test_parameter" value=""a"" /> | ||
<has_json_property_with_value property="integer_parameter" value="1" /> | ||
</expand> | ||
</test> | ||
<test> | ||
<conditional name="conditional_parameter"> | ||
<param name="test_parameter" value="a" /> | ||
<param name="integer_parameter" value="4" /> | ||
</conditional> | ||
<expand macro="assert_output"> | ||
<has_line line="test: a" /> | ||
</expand> | ||
<expand macro="assert_inputs_json"> | ||
<has_json_property_with_value property="test_parameter" value=""a"" /> | ||
<has_json_property_with_value property="integer_parameter" value="4" /> | ||
</expand> | ||
</test> | ||
<test> | ||
<conditional name="conditional_parameter"> | ||
<param name="test_parameter" value="b" /> | ||
<param name="boolean_parameter" value="true" /> | ||
</conditional> | ||
<expand macro="assert_output"> | ||
<has_line line="test: b" /> | ||
</expand> | ||
<expand macro="assert_inputs_json"> | ||
<has_json_property_with_value property="test_parameter" value=""b"" /> | ||
<has_json_property_with_value property="boolean_parameter" value="true" /> | ||
</expand> | ||
</test> | ||
</tests> | ||
</tool> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters