Skip to content

Commit

Permalink
Added switch test case with numbers in case
Browse files Browse the repository at this point in the history
  • Loading branch information
siad007 authored Jan 14, 2025
1 parent 579928d commit 27db7f5
Showing 1 changed file with 14 additions and 0 deletions.
14 changes: 14 additions & 0 deletions tests/etc/tasks/system/SwitchTest.xml
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,20 @@
</default>
</switch>
</target>
<target name="testSwitchCaseNumbers">
<property name="foo" value="1"/>
<switch value="${foo}">
<case value="0">
<echo message="The value of property foo is 0" />
</case>
<case value="1">
<echo message="The value of property foo is 1" />
</case>
<default>
<echo message="The value of property foo is not sensible" />
</default>
</switch>
</target>
<target name="testSwitchDefault">
<property name="bar" value="test"/>
<switch value="${bar}">
Expand Down

0 comments on commit 27db7f5

Please sign in to comment.