commons-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From d...@apache.org
Subject cvs commit: jakarta-commons/jelly/jelly-tags/fmt/src/test/org/apache/commons/jelly/tags/fmt suite.jelly
Date Wed, 08 Sep 2004 05:15:28 GMT
dion        2004/09/07 22:15:28

  Modified:    jelly/jelly-tags/fmt/src/test/org/apache/commons/jelly/tags/fmt
                        suite.jelly
  Log:
  detab
  
  Revision  Changes    Path
  1.6       +104 -104  jakarta-commons/jelly/jelly-tags/fmt/src/test/org/apache/commons/jelly/tags/fmt/suite.jelly
  
  Index: suite.jelly
  ===================================================================
  RCS file: /home/cvs/jakarta-commons/jelly/jelly-tags/fmt/src/test/org/apache/commons/jelly/tags/fmt/suite.jelly,v
  retrieving revision 1.5
  retrieving revision 1.6
  diff -u -r1.5 -r1.6
  --- suite.jelly	27 Aug 2004 08:21:32 -0000	1.5
  +++ suite.jelly	8 Sep 2004 05:15:27 -0000	1.6
  @@ -15,111 +15,111 @@
     limitations under the License.
   -->
   <test:suite xmlns:j="jelly:core" 
  -			xmlns:fmt="jelly:fmt"
  -			xmlns:m="jelly:ant"
  -			xmlns:b="jelly:beanshell" 
  +            xmlns:fmt="jelly:fmt"
  +            xmlns:m="jelly:ant"
  +            xmlns:b="jelly:beanshell" 
               xmlns:test="jelly:junit" 
               xmlns:log="jelly:log">
   
  -	<test:case name="testSimple" xmlns="dummy">
  -		<j:set var="keyvar" value="key2"/>
  -		<fmt:bundle basename="org.apache.commons.jelly.tags.fmt.abc">
  -			<fmt:message key="key1" var="dummyKey1"/>
  -			<fmt:message var="dummyKey2">${keyvar}</fmt:message>
  -			<fmt:message var="dummyKeyInvalid">invalid.key</fmt:message>
  -		</fmt:bundle>
  -
  -		<m:echo>i10n content is </m:echo>
  -		<m:echo>key1: '${dummyKey1}'</m:echo>
  -		<m:echo>key2: '${dummyKey2}'</m:echo>
  -		<m:echo>keyInvalid: '${dummyKeyInvalid}'</m:echo>
  -    
  -		<test:assertEquals expected="value1" actual="${dummyKey1}" />
  -		<test:assertEquals expected="value2" actual="${dummyKey2}" />
  -		<test:assertEquals expected="???invalid.key???" actual="${dummyKeyInvalid}" />
  -	</test:case>
  -	
  -	<test:case name="testParam" xmlns="dummy">
  -		<j:set var="keyvar" value="key3"/>
  -		<j:set var="valuevar" value="param1"/>
  -
  -		<fmt:bundle basename="org.apache.commons.jelly.tags.fmt.abc">
  -			<fmt:message var="dummyKey3">${keyvar}<fmt:param value="${valuevar}"/>
  -				<fmt:param value="param2"/>
  -			</fmt:message>
  -		</fmt:bundle>
  -
  -		<m:echo>i10n content is </m:echo>
  -		<m:echo>key3: '${dummyKey3}'</m:echo>
  -    
  -		<test:assertEquals expected="value3 param1 param2" actual="${dummyKey3}" />
  -
  -		<fmt:bundle basename="org.apache.commons.jelly.tags.fmt.abc">
  -			<fmt:message var="dummyKey3" key="${keyvar}"><fmt:param value="${valuevar}"/>
  -				<fmt:param value="param2"/>
  -			</fmt:message>
  -		</fmt:bundle>
  -
  -		<m:echo>i10n content is </m:echo>
  -		<m:echo>key3: '${dummyKey3}'</m:echo>
  -    
  -		<test:assertEquals expected="value3 param1 param2" actual="${dummyKey3}" />
  -	</test:case>
  -
  -	<test:case name="testParam2" xmlns="dummy">
  -		<j:set var="keyvar" value="key4"/>
  -		<j:set var="valuevar" value="param1"/>
  -		<j:set var="intvalue" value="123"/>
  -		<j:new className="java.lang.Integer" var="intValue">
  -			<j:arg value="123"/>
  -		</j:new>
  -		<test:assertEquals expected="java.lang.Integer" actual="${intValue.class.name}" />
  -		<fmt:bundle basename="org.apache.commons.jelly.tags.fmt.abc">
  -			<fmt:message var="dummyKey4">${keyvar}<fmt:param value="${valuevar}"/>
  -				<fmt:param value="param2"/>
  -				<fmt:param value='${intValue}'/>
  -			</fmt:message>
  -		</fmt:bundle>
  -
  -		<m:echo>i10n content is </m:echo>
  -		<m:echo>key4: '${dummyKey4}'</m:echo>
  -    
  -		<test:assertEquals expected="value4 param1 param2 123" actual="${dummyKey4}" />
  -	</test:case>
  -
  -
  -	<test:case name="testPrefix" xmlns="dummy">
  -		<fmt:bundle basename="org.apache.commons.jelly.tags.fmt.xyz" prefix="123.">
  -			<fmt:message key="key1" var="dummyKey1"/>
  -			<fmt:message var="dummyKey2">key2</fmt:message>
  -			<fmt:message var="dummyKeyInvalid">invalid.key</fmt:message>
  -		</fmt:bundle>
  -
  -		<m:echo>i10n content is </m:echo>
  -		<m:echo>key1: '${dummyKey1}'</m:echo>
  -		<m:echo>key2: '${dummyKey2}'</m:echo>
  -		<m:echo>keyInvalid: '${dummyKeyInvalid}'</m:echo>
  -    
  -		<test:assertEquals expected="value1" actual="${dummyKey1}" />
  -		<test:assertEquals expected="value2" actual="${dummyKey2}" />
  -		<test:assertEquals expected="???123.invalid.key???" actual="${dummyKeyInvalid}" />
  -	</test:case>
  -	
  -	<test:case name="testSetLocale" xmlns="dummy">
  -		<fmt:setLocale value="zh"/>
  -		<fmt:bundle basename="org.apache.commons.jelly.tags.fmt.xyz" prefix="123.">
  -			<fmt:message key="key1" var="dummyKey1"/>
  -			<fmt:message var="dummyKey2">key2</fmt:message>
  -			<fmt:message var="dummyKeyInvalid">invalid.key</fmt:message>
  -		</fmt:bundle>
  -
  -		<m:echo>i10n content is </m:echo>
  -		<m:echo>key1: '${dummyKey1}'</m:echo>
  -		<m:echo>key2: '${dummyKey2}'</m:echo>
  -		<m:echo>keyInvalid: '${dummyKeyInvalid}'</m:echo>
  -    
  -		<test:assertEquals expected="value1-zh" actual="${dummyKey1}" />
  -		<test:assertEquals expected="value2-zh" actual="${dummyKey2}" />
  -		<test:assertEquals expected="???123.invalid.key???" actual="${dummyKeyInvalid}" />
  -	</test:case>
  +    <test:case name="testSimple" xmlns="dummy">
  +        <j:set var="keyvar" value="key2"/>
  +        <fmt:bundle basename="org.apache.commons.jelly.tags.fmt.abc">
  +            <fmt:message key="key1" var="dummyKey1"/>
  +            <fmt:message var="dummyKey2">${keyvar}</fmt:message>
  +            <fmt:message var="dummyKeyInvalid">invalid.key</fmt:message>
  +        </fmt:bundle>
  +
  +        <m:echo>i10n content is </m:echo>
  +        <m:echo>key1: '${dummyKey1}'</m:echo>
  +        <m:echo>key2: '${dummyKey2}'</m:echo>
  +        <m:echo>keyInvalid: '${dummyKeyInvalid}'</m:echo>
  +    
  +        <test:assertEquals expected="value1" actual="${dummyKey1}" />
  +        <test:assertEquals expected="value2" actual="${dummyKey2}" />
  +        <test:assertEquals expected="???invalid.key???" actual="${dummyKeyInvalid}"
/>
  +    </test:case>
  +    
  +    <test:case name="testParam" xmlns="dummy">
  +        <j:set var="keyvar" value="key3"/>
  +        <j:set var="valuevar" value="param1"/>
  +
  +        <fmt:bundle basename="org.apache.commons.jelly.tags.fmt.abc">
  +            <fmt:message var="dummyKey3">${keyvar}<fmt:param value="${valuevar}"/>
  +                <fmt:param value="param2"/>
  +            </fmt:message>
  +        </fmt:bundle>
  +
  +        <m:echo>i10n content is </m:echo>
  +        <m:echo>key3: '${dummyKey3}'</m:echo>
  +    
  +        <test:assertEquals expected="value3 param1 param2" actual="${dummyKey3}" />
  +
  +        <fmt:bundle basename="org.apache.commons.jelly.tags.fmt.abc">
  +            <fmt:message var="dummyKey3" key="${keyvar}"><fmt:param value="${valuevar}"/>
  +                <fmt:param value="param2"/>
  +            </fmt:message>
  +        </fmt:bundle>
  +
  +        <m:echo>i10n content is </m:echo>
  +        <m:echo>key3: '${dummyKey3}'</m:echo>
  +    
  +        <test:assertEquals expected="value3 param1 param2" actual="${dummyKey3}" />
  +    </test:case>
  +
  +    <test:case name="testParam2" xmlns="dummy">
  +        <j:set var="keyvar" value="key4"/>
  +        <j:set var="valuevar" value="param1"/>
  +        <j:set var="intvalue" value="123"/>
  +        <j:new className="java.lang.Integer" var="intValue">
  +            <j:arg value="123"/>
  +        </j:new>
  +        <test:assertEquals expected="java.lang.Integer" actual="${intValue.class.name}"
/>
  +        <fmt:bundle basename="org.apache.commons.jelly.tags.fmt.abc">
  +            <fmt:message var="dummyKey4">${keyvar}<fmt:param value="${valuevar}"/>
  +                <fmt:param value="param2"/>
  +                <fmt:param value='${intValue}'/>
  +            </fmt:message>
  +        </fmt:bundle>
  +
  +        <m:echo>i10n content is </m:echo>
  +        <m:echo>key4: '${dummyKey4}'</m:echo>
  +    
  +        <test:assertEquals expected="value4 param1 param2 123" actual="${dummyKey4}"
/>
  +    </test:case>
  +
  +
  +    <test:case name="testPrefix" xmlns="dummy">
  +        <fmt:bundle basename="org.apache.commons.jelly.tags.fmt.xyz" prefix="123.">
  +            <fmt:message key="key1" var="dummyKey1"/>
  +            <fmt:message var="dummyKey2">key2</fmt:message>
  +            <fmt:message var="dummyKeyInvalid">invalid.key</fmt:message>
  +        </fmt:bundle>
  +
  +        <m:echo>i10n content is </m:echo>
  +        <m:echo>key1: '${dummyKey1}'</m:echo>
  +        <m:echo>key2: '${dummyKey2}'</m:echo>
  +        <m:echo>keyInvalid: '${dummyKeyInvalid}'</m:echo>
  +    
  +        <test:assertEquals expected="value1" actual="${dummyKey1}" />
  +        <test:assertEquals expected="value2" actual="${dummyKey2}" />
  +        <test:assertEquals expected="???123.invalid.key???" actual="${dummyKeyInvalid}"
/>
  +    </test:case>
  +    
  +    <test:case name="testSetLocale" xmlns="dummy">
  +        <fmt:setLocale value="zh"/>
  +        <fmt:bundle basename="org.apache.commons.jelly.tags.fmt.xyz" prefix="123.">
  +            <fmt:message key="key1" var="dummyKey1"/>
  +            <fmt:message var="dummyKey2">key2</fmt:message>
  +            <fmt:message var="dummyKeyInvalid">invalid.key</fmt:message>
  +        </fmt:bundle>
  +
  +        <m:echo>i10n content is </m:echo>
  +        <m:echo>key1: '${dummyKey1}'</m:echo>
  +        <m:echo>key2: '${dummyKey2}'</m:echo>
  +        <m:echo>keyInvalid: '${dummyKeyInvalid}'</m:echo>
  +    
  +        <test:assertEquals expected="value1-zh" actual="${dummyKey1}" />
  +        <test:assertEquals expected="value2-zh" actual="${dummyKey2}" />
  +        <test:assertEquals expected="???123.invalid.key???" actual="${dummyKeyInvalid}"
/>
  +    </test:case>
   </test:suite>
  
  
  

---------------------------------------------------------------------
To unsubscribe, e-mail: commons-dev-unsubscribe@jakarta.apache.org
For additional commands, e-mail: commons-dev-help@jakarta.apache.org


Mime
View raw message