cdece02001-01-29Per Hedbor <comment>Empty tests</comment> <test> <rxml>ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz1234567890&amp;&lt;&gt;&#40;ÅäÖ</rxml> <result>ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz1234567890&amp;&lt;&gt;&#40;ÅäÖ</result> </test> <test> <rxml><br><b><i><p>x<x></p></b></i><br><br/><br /><BR></rxml> <result><br><b><i><p>x<x></p></b></i><br><br/><br /><BR></result> </test> <test> <rxml></rxml> <result></result> </test> <test> <rxml> x x x </rxml> <result> x x x </result> </test>
5a1b8a2001-03-24Martin Nilsson <test> <rxml><set variable="var.x" value="Ensuring integrity between tests"/></rxml> <result></result> </test> <test> <rxml>&var.x;</rxml> <result></result> </test> <!-- ............................................................ -->
cdece02001-01-29Per Hedbor <comment>True/False/Else/Then</comment> <test> <rxml><true/><then>1</then><else>0</else></rxml> <result>1</result> </test> <test> <rxml><false/><then>1</then><else>0</else></rxml> <result>0</result> </test> <test> <rxml><true/><then>a</then>b<then>c</then><else>d</else></rxml> <result>abc</result> </test> <test> <rxml><false/><else>a</else>b<else>c</else><then>d</then></rxml> <result>abc</result> </test> <test> <rxml><set variable='var.x' value='2'/><true/><else>x<set variable='var.x' value='3'/></else>&var.x;</rxml> <result>2</result> </test> <test> <rxml><set variable='var.x' value='2'/><false/><then>x<set variable='var.x' value='3'/></then>&var.x;</rxml> <result>2</result> </test>
5a1b8a2001-03-24Martin Nilsson <!-- ............................................................ -->
cdece02001-01-29Per Hedbor <comment>Case</comment> <test> <rxml><case case=upper>aA</case></rxml> <result>AA</result> </test> <test> <rxml><case>aA</case></rxml> <result>aA</result> </test> <test> <rxml><case case=capitalize>aaAa</case></rxml> <result>AaAa</result> </test> <test> <rxml><case case=lower>aA</case></rxml> <result>aa</result> </test> <test> <rxml><case case="upper">a &amp; &quot; <br /></case></rxml> <result>A &amp; &#34; <br /></result> </test>
5a1b8a2001-03-24Martin Nilsson <!-- ............................................................ -->
cdece02001-01-29Per Hedbor <comment>Comment</comment> <test> <rxml><set variable='var.i' value='3'/><comment preparse><set variable=var.i value='4'/>x</comment>&var.i;</rxml> <result>4</result> </test> <test> <rxml><set variable='var.i' value='3'/><comment><set variable='var.i' value='4'/>x</comment>&var.i;</rxml> <result>3</result> </test> <test> <rxml><comment>a</comment></rxml> <result></result> </test>
9057062001-01-30Martin Nilsson <test> <rxml><set variable="var.i">3</set><?comment <set variable="var.i">5</set>?>5</set>?>&var.i;</rxml> <result>3</result> </test> <test> <rxml>a<?comment <b <?comment ?> ?>c</rxml> <result>a ?> ?>c</rxml> <result>a ?>c</result> </test>
cdece02001-01-29Per Hedbor 
5a1b8a2001-03-24Martin Nilsson 
cdece02001-01-29Per Hedbor <!-- ............................................................ --> <comment>Define/undefine</comment> <test> <rxml><define if='x'>3</define><if x='3'>1</if><undefine if='x'/><if x='3'>1</if><else>0</else></rxml> <result>10</result> </test> <test> <rxml><define tag='a'>&_.b;&a.c;</define><a c='2' b='1'/></rxml> <result>12</result> </test> <test> <rxml><define tag='q'>&_.args:none;</define><q a='b'/></rxml> <result>a="b"</result> </test> <test> <rxml><define variable='var.i'>b</define>a&var.i;<undefine variable='var.i'/>c&var.i;d</rxml> <result>abcd</result> </test> <test> <rxml><define variable="var.i" trimwhites="1"> a </define>x&var.i;</rxml> <result>xa</result> </test>
c7d3942001-05-22Martin Nilsson  <test> <rxml><define variable="var.i" trimwhites="1" />&var.i;</rxml> <result></result> </test>
cdece02001-01-29Per Hedbor  <test> <rxml><define container='x'><p ::='&_.args;'>&_.args;<contents/></p></define><x align='center'>hej</x></rxml> <result><p align="center">hej</p></result> </test> <test> <rxml><define tag='a'>A</define><a/><define tag='b'><a/>B</define><b/></rxml> <result>AAB</result> </test> <test> <rxml><define tag='q'>b</define>a<q/><undefine tag='q'/><q/></rxml> <result>ab<q/></result> </test> <test> <rxml><define tag='x'>y</define><x/><if true><x/></if></rxml> <result>yy</result> </test> <test> <rxml><define container='x'>a<contents/>c</define><x>b</x><undefine container='x'/><x>d</x></rxml> <result>abc<x>d</x></result> </test> <test> <rxml><define tag="ä">a</define><define tag="Ä">A</define>x<ä/><Ä/></rxml> <result>xaA</result> </test> <test> <rxml><define tag='x'><attrib name='y'>z</attrib>a&_.y;</define><x/>b<x y='c'/></rxml> <result>azbac</result> </test> <test> <rxml><define container='x'><attrib name='y'>z</attrib>a<contents/>&_.y;d</define><x y='c'>b</x>e<x>b</x></rxml> <result>abcdeabzd</result> </test> <test> <rxml><define container='x'>::&_.contents;::</define>a<x>b</x>c</rxml> <result>a::b::c</result> </test> <test> <rxml><define tag='x'><attrib name="y">z</attrib>&_.rest-args:none;</define><x a="b"/></rxml> <result>a="b"</result> </test> <test> <rxml><define tag="x" trimwhites="1"> <attrib name="y"> </attrib> a&_.y; </define><x/></rxml> <result>a </result> </test>
c7d3942001-05-22Martin Nilsson  <test> <rxml><define tag="x" trimwhites="1" /><x trimwhites="1"/></rxml> <result></result> </test>
cdece02001-01-29Per Hedbor  <test>
1f32b52001-06-18Martin Stjernholm <rxml><define tag="x"> <attrib name="y"> </attrib> a&_.y; </define><x trimwhites="1"/></rxml> <result> a </result> </test> <test> <rxml><define tag="x"><!-- foo --><attrib name="y">y</attrib><?x?><attrib name="z">z</attrib>&_.y;&_.z;</define><x/></rxml> <result><!-- foo --><?x?><attrib name="z">z</attrib>y</result> </test> <test> <rxml><define tag="x"> <attrib name="y">y</attrib>x<attrib name="z">z</attrib>&_.y;&_.z;</define><x/></rxml> <result> x<attrib name="z">z</attrib>y</result> </test> <test> <rxml><define tag="x"><attrib name="y">y</attrib><![CDATA[]]><attrib name="z">z</attrib>&_.y;&_.z;</define><x/></rxml> <result><![CDATA[]]><attrib name="z">z</attrib>y</result> </test> <test> <rxml><define tag="x"><attrib name="y">y</attrib>&_.y;<attrib name="z">z</attrib>&_.y;&_.z;</define><x/></rxml>
cdece02001-01-29Per Hedbor <result>y<attrib name="z">z</attrib>y</result> </test> <test> <rxml><define container="x"> a&_.contents; </define><x trimwhites="1">b </x></rxml> <result> ab </result> </test> <test> <rxml><define tag="x">&_.y;&x.y;</define><x y="z"/></rxml> <result>zz</result> </test> <test> <rxml><define tag="x" scope="p">&_.y;&p.y;</define><x y="z"/></rxml> <result>zz</result> </test> <test> <rxml><define tag="x">&var.x;</define><set variable="var.x">y</set><x/></rxml> <result>y</result> </test> <test> <rxml><define tag="x" preparse="1">&var.x;</define><set variable="var.x">y</set><x/></rxml> <result></result> </test>
c7d3942001-05-22Martin Nilsson 
1f32b52001-06-18Martin Stjernholm <test> <rxml><define tag="x"><attrib name="y">1</attrib> <![CDATA[</attrib>]]> <attrib name="z">2</attrib> &_.y;:&_.z;</define><x/></rxml>
c7d3942001-05-22Martin Nilsson <result> <![CDATA[</attrib>]]> <attrib name="z">2</attrib> 1:</result> </test> <test> <rxml><define tag="x"><attrib name="y">hej</attrib><maketag type="tag" name="&_.y;">&_.y; <attrib name="foo">bar</attrib></maketag></define><x/></rxml> <result><hej foo="bar" /></result> </test>
1f32b52001-06-18Martin Stjernholm  <test> <rxml type="string"> <emit source="values" values="1,2" split=","> <if variable="_.value = 1"> <define tag="t">a</define> </if> <else> <define tag="t">b</define> </else> <t/> </emit> </rxml> <result>ab</result> </test> <!-- ............................................................ --> <comment>Type tests</comment> <test> <rxml type="any"><case case="upper"> a </case></rxml> <result>A</result> </test> <test> <rxml type="scalar"><case case="upper"> a </case></rxml> <result>A</result> </test> <test> <rxml type="string">|<case case="upper"> a </case>|</rxml> <result>|A|</result> </test> <test> <rxml type="text/*">|<case case="upper"> a </case>|</rxml> <result>| A |</result> </test> <test> <rxml type="text/html">|<case case="upper"> a </case>|</rxml> <result>| A |</result> </test>
cdece02001-01-29Per Hedbor 
5a1b8a2001-03-24Martin Nilsson 
cdece02001-01-29Per Hedbor <!-- ............................................................ --> <comment>String number test</comment>
efa4402001-05-17Martin Nilsson <test>
cdece02001-01-29Per Hedbor <rxml><number lang=swe num=43 /></rxml> <result>fyrtiotre</result> </test>
efa4402001-05-17Martin Nilsson <test>
cdece02001-01-29Per Hedbor <rxml><number lang=sv num=43 /></rxml> <result>fyrtiotre</result> </test>
efa4402001-05-17Martin Nilsson <test>
cdece02001-01-29Per Hedbor <rxml><number num=42 /></rxml> <result>fortytwo</result> </test>
efa4402001-05-17Martin Nilsson  <test> <rxml><number num=11 type=roman /></rxml> <result>XI</result> </test> <test> <rxml><number num=61254312 type=memory /></rxml> <result>58.4 Mb</result> </test>
cdece02001-01-29Per Hedbor 
5a1b8a2001-03-24Martin Nilsson 
cdece02001-01-29Per Hedbor <!-- ............................................................ --> <comment>IfIs operands</comment> <test> <rxml><set variable='var.i' value='10' /><set variable='var.j' value='0'/><set variable="var.x" value=""/><if sizeof="var.x is 0">5</if></rxml> <result>5</result> </test> <test> <rxml><set variable='var.i' value='10' /><set variable='var.j' value='0'/><if variable="var.i is 8,9,10,11">1</if></rxml> <result>1</result> </test> <test> <rxml><set variable='var.i' value='10' /><set variable='var.j' value='0'/><if variable="var.i != 11">1</if></rxml> <result>1</result> </test> <test> <rxml><set variable='var.i' value='10' /><set variable='var.j' value='0'/><if variable="var.foo">1</if></rxml> <result></result> </test> <test> <rxml><set variable='var.i' value='10' /><set variable='var.j' value='0'/><set variable="var.x" value="-5"/><if variable="var.x < 3">1</if></rxml> <result>1</result> </test> <test> <rxml><set variable='var.i' value='10' /><set variable='var.j' value='0'/><if variable="var.i < 11">1</if><else>0</else></rxml> <result>1</result> </test> <test> <rxml><set variable='var.i' value='10' /><set variable='var.j' value='0'/><if variable="var.i == 10">1</if></rxml> <result>1</result> </test> <test> <rxml><set variable='var.i' value='10' /><set variable='var.j' value='0'/><if variable="var.j < 0">1</if><else>0</else></rxml> <result>0</result> </test> <test> <rxml><set variable='var.i' value='10' /><set variable='var.j' value='0'/><if variable="var.i is 11">1</if><else>0</else></rxml> <result>0</result> </test> <test> <rxml><set variable='var.i' value='10' /><set variable='var.j' value='0'/><if variable="var.i == ?1,?0">8</if></rxml> <result>8</result> </test> <test> <rxml><set variable='var.i' value='10' /><set variable='var.j' value='0'/><if variable="var.i is ?">6</if></rxml> <result></result> </test> <test> <rxml><set variable='var.i' value='10' /><set variable='var.j' value='0'/><if variable="var.i is *">5</if></rxml> <result>5</result> </test> <test> <rxml><set variable='var.i' value='10' /><set variable='var.j' value='0'/><set variable="var.x" value="-30"/><if variable="var.x < -2">1</if></rxml> <result>1</result> </test> <test> <rxml><set variable='var.i' value='10' /><set variable='var.j' value='0'/><if variable="var.i < 10">1</if><else>0</else></rxml> <result>0</result> </test> <test> <rxml><set variable='var.i' value='10' /><set variable='var.j' value='0'/><if variable="var.i = 10">1</if></rxml> <result>1</result> </test> <test> <rxml><set variable='var.i' value='10' /><set variable='var.j' value='0'/><if variable="var.i is 10">1</if></rxml> <result>1</result> </test> <test> <rxml><set variable='var.i' value='10' /><set variable='var.j' value='0'/><if variable="var.i is ??">7</if></rxml> <result>7</result> </test> <test> <rxml><set variable='var.i' value='10' /><set variable='var.j' value='0'/><if variable="var.i > 9">1</if><else>0</else></rxml> <result>1</result> </test> <test> <rxml><set variable='var.i' value='10' /><set variable='var.j' value='0'/><if variable="var.i is *10*">3</if></rxml> <result>3</result> </test> <test> <rxml><set variable='var.i' value='10' /><set variable='var.j' value='0'/><if variable="var.j > 0">1</if><else>0</else></rxml> <result>0</result> </test> <test> <rxml><set variable='var.i' value='10' /><set variable='var.j' value='0'/><if variable="var.i is *11*">4</if></rxml> <result></result> </test> <test> <rxml><set variable='var.i' value='10' /><set variable='var.j' value='0'/><if variable="var.j > -1">1</if><else>0</else></rxml> <result>1</result> </test> <test> <rxml><set variable='var.i' value='10' /><set variable='var.j' value='0'/><if variable="var.j != 0">1</if><else>0</else></rxml> <result>0</result> </test> <test> <rxml><set variable='var.i' value='10' /><set variable='var.j' value='0'/><if variable="var.j is 0">1</if></rxml> <result>1</result> </test> <test> <rxml><set variable='var.i' value='10' /><set variable='var.j' value='0'/><if sizeof="var.i == 2">3</if></rxml> <result>3</result> </test> <test> <rxml><set variable='var.i' value='10' /><set variable='var.j' value='0'/><if variable="var.i > 10">1</if><else>0</else></rxml> <result>0</result> </test> <test> <rxml><set variable='var.i' value='10' /><set variable='var.j' value='0'/><if variable="var.i is 8,9,11">2</if></rxml> <result></result> </test> <test> <rxml><set variable='var.i' value='10' /><set variable='var.j' value='0'/><if variable="var.j < 1">1</if><else>0</else></rxml> <result>1</result> </test> <test> <rxml><set variable='var.i' value='10' /><set variable='var.j' value='0'/><if variable="var.i != 10">1</if><else>0</else></rxml> <result>0</result> </test> <test> <rxml><set variable='var.i' value='10' /><set variable='var.j' value='0'/><if variable="var.j != 1">1</if></rxml> <result>1</result> </test> <test> <rxml><set variable='var.i' value='10' /><set variable='var.j' value='0'/><if sizeof="var.i != 2">4</if></rxml> <result></result> </test> <test> <rxml><set variable='var.i' value='10' /><set variable='var.j' value='0'/><if variable="var.i">2</if></rxml> <result>2</result> </test> <test> <rxml><set variable='var.i' value='10' /><set variable='var.j' value='0'/><set variable="var.x" value="-0.2"/><if variable="var.x > -0.3">1</if><else>0</else></rxml> <result>1</result> </test>
505e4c2001-06-11Martin Stjernholm  <test> <rxml><emit source="values" values="1,2,3" split=","><if variable="_.value = 1">&_.value;</if></emit></rxml> <result>1</result> </test>
cdece02001-01-29Per Hedbor 
5a1b8a2001-03-24Martin Nilsson 
cdece02001-01-29Per Hedbor <!-- ............................................................ --> <comment>Sort</comment> <test> <rxml><sort separator=,>1,3,5,0,8</sort></rxml> <result>0,1,3,5,8</result> </test> <test> <rxml><sort>1 3 5 0 8 </sort></rxml> <result>0 1 3 5 8 </result> </test>
5a1b8a2001-03-24Martin Nilsson 
cdece02001-01-29Per Hedbor <!-- ............................................................ --> <comment>If caller test</comment> <test> <rxml><set variable='var.a' value='foo'/><if match="&var.a; is foo">&var.a;x</if><else>y</else>&var.a;</rxml> <result>xfoo</result> </test> <test> <rxml><if match="foo is bar">x</if><else>y</else></rxml> <result>y</result> </test> <test> <rxml><if match="foo is foo">x</if><else>y</else></rxml> <result>x</result> </test> <test> <rxml><set variable='var.a' value='0'/><if variable="var.a is 0">x</if><else>y</else></rxml> <result>x</result> </test> <test> <rxml><set variable='a' value='4' scope='var'/><if variable="var.a is 4">x</if><else>y</else></rxml> <result>x</result> </test> <test> <rxml><set variable='var.a' value='3'/><if variable="var.a is 3">x</if><else>y</else></rxml> <result>x</result> </test>
5a1b8a2001-03-24Martin Nilsson 
cdece02001-01-29Per Hedbor <!-- ............................................................ --> <comment>Strlen</comment> <test> <rxml><strlen>a b</strlen></rxml> <result>3</result> </test> <test> <rxml><strlen>Roxen<b>&ouml;</b></strlen></rxml> <result>18</result> </test> <test> <rxml>a<strlen>b</strlen>c</rxml> <result>a1c</result> </test> <test> <rxml><strlen></strlen></rxml> <result>0</result> </test>
5a1b8a2001-03-24Martin Nilsson 
cdece02001-01-29Per Hedbor <!-- ............................................................ --> <comment>User Ifs</comment> <test> <rxml><define if=q><if variable="var.i = 4"></if></define><if q>a</if><set variable=var.i value='3'/><if q>b</if><set variable='var.i' value='4'/><if q>c</if></rxml> <result>c</result> </test> <test> <rxml><if q>X</if><else>Y</else></rxml> <result>Y</result> </test> <test> <rxml><define if=q>a</define><if q=a>x</if><if q=b>b</if><if q>c</if></rxml> <result>x</result> </test> <test> <rxml><true/><define if=q><false/></define><then>A</then><if q>F</if><if q=1>F</if></rxml> <result>A</result> </test> <test> <rxml><false/><define if=q><true/></define><then>A</then><if q>T</if><if q=1>F</if></rxml> <result>T</result> </test>
913e852001-06-25Martin Stjernholm  <!-- ............................................................ --> <comment>Cond</comment> <test> <rxml><cond><default>x</default></cond></rxml> <result>x</result> </test>
5a1b8a2001-03-24Martin Nilsson 
cdece02001-01-29Per Hedbor <!-- ............................................................ --> <comment>Loops (for)</comment> <test> <rxml><for variable=var.i from=3 to=3><insert variable=var.i></for></rxml> <result>3</result> </test> <test> <rxml><for variable=var.i from=1 to=5>&var.i;</for>&var.i;</rxml> <result>123455</result> </test> <test> <rxml><for from=10 to=1>x</for></rxml> <result>xxxxxxxxxx</result> </test> <test> <rxml><for variable=var.i from=10 to=5><insert variable=var.i></for></rxml> <result>1098765</result> </test> <test> <rxml><for from=1 to=10>x</for></rxml> <result>xxxxxxxxxx</result> </test> <test> <rxml><for variable=var.i from=3 to=3 step=-1><insert variable=var.i></for></rxml> <result>3</result> </test> <test> <rxml><for variable=var.i from=1 to=3><for variable=var.j from=7 to=9><insert variable=var.j /></for>:<insert variable=var.i />;</for></rxml> <result>789:1;789:2;789:3;</result> </test> <test> <rxml><set variable='var.i' value='3'/><for variable='var.i' from='1' to='10' step='2'><insert variable='var.i'/></for></rxml> <result>13579</result> </test>
5a1b8a2001-03-24Martin Nilsson 
cdece02001-01-29Per Hedbor <!-- ............................................................ --> <comment>If tests</comment> <test> <rxml><define if=p><true/></define><define if=q><false/></define><if p and q>p&q</if><if p and p>p</if><if q and q>q</if></rxml> <result>p</result> </test> <test> <rxml><define if=p><true/></define><define if=q><false/></define><true/><if true>a</if><else>b</else><then>c</then></rxml> <result>ac</result> </test> <test> <rxml><define if=p><true/></define><define if=q><false/></define><if not p q>p&q</if><if not p p>p</if><if not q q>q</if></rxml> <result>p&qq</result> </test> <test> <rxml><define if=p><true/></define><define if=q><false/></define><false/><if false>a</if><else>b</else></rxml> <result>a</result> </test> <test> <rxml><define if=p><true/></define><define if=q><false/></define><false/><if p>A<if false>B</if></if></rxml> <result>AB</result> </test> <test> <rxml><define if=p><true/></define><define if=q><false/></define><if not p>p</if><if not q>q</if></rxml> <result>q</result> </test> <test> <rxml><define if=p><true/></define><define if=q><false/></define><false/><if true>a</if><else>b</else><then>c</then></rxml> <result>b</result> </test> <test> <rxml><define if=p><true/></define><define if=q><false/></define><if p q>p&q</if><if p p>p</if><if q q>q</if></rxml> <result>p</result> </test> <test> <rxml><define if=p><true/></define><define if=q><false/></define><if p>p</if><if q>q</if></rxml> <result>p</result> </test> <test> <rxml><define if=p><true/></define><define if=q><false/></define><if not p and q>p&q</if><if not p and p>p</if><if not q and q>q</if></rxml> <result>p&qq</result> </test> <test> <rxml><define if=p><true/></define><define if=q><false/></define><if not p or q>p|q</if><if not p or p>p</if><if not q or q>q</if></rxml> <result>q</result> </test> <test> <rxml><define if=p><true/></define><define if=q><false/></define><if p or q>p|q</if><if p or p>p</if><if q or q>q</if></rxml> <result>p|qp</result> </test> <test> <rxml><define if=p><true/></define><define if=q><false/></define><true/><if false>a</if><else>b</else></rxml> <result>b</result> </test>
9057062001-01-30Martin Nilsson 
5a1b8a2001-03-24Martin Nilsson 
9057062001-01-30Martin Nilsson <!-- ............................................................ --> <comment>Elseif tests</comment> <test> <rxml><set variable="var.x">Y</set><if variable="var.x = Y">A</if><elseif variable="var.x = Y">B</elseif><else>C</else></rxml> <result>A</result> </test> <test> <rxml><set variable="var.x">Y</set><if variable="var.x = X">A</if><elseif variable="var.x = Y">B</elseif><else>C</else></rxml> <result>B</result> </test> <test> <rxml><set variable="var.x">Z</set><if variable="var.x = Y">X</if><elseif variable="var.x = Y">B</elseif><else>C</else></rxml> <result>C</result> </test>
5a1b8a2001-03-24Martin Nilsson 
9057062001-01-30Martin Nilsson <!-- ............................................................ --> <comment>If plugins</comment> <test> <rxml><if exists="/index.html">yes</if></rxml> <result>yes</result> </test> <test> <rxml><if exists="/does_not_exist">yes</if></rxml> <result></result> </test> <test> <rxml><if nserious="1">yes</if></rxml> <result></result> </test> <test> <rxml><if module="rxmltags">yes</if></rxml> <result>yes</result> </test> <test> <rxml><if module="nomodule">yes</if></rxml> <result></result> </test> <test> <rxml><true/><if true="1">yes</if></rxml> <result>yes</result> </test> <test> <rxml><false/><if true="1">yes</if></rxml> <result></result> </test> <test> <rxml><true/><if false="1">yes</if></rxml> <result></result> </test> <test> <rxml><false/><if false="1">yes</if></rxml> <result>yes</result> </test> <test> <rxml><if match="buhu is buhu">1</if></rxml> <result>1</result> </test> <test> <rxml><if match="Buhu is buhu">1</if></rxml> <result>1</result> </test> <test> <rxml><if Match="Buhu is buhu">1</if></rxml> <result></result> </test> <test> <rxml><if Match="buhu is buhu">1</if></rxml> <result>1</result> </test> <test> <rxml><if match="a = a">1</if></rxml> <result>1</result> </test> <test> <rxml><if match="a = a = a = a">1</if></rxml> <result></result> </test> <test> <rxml><if sizeof="var.basun = 0">1</if></rxml> <result>1</result> </test> <test> <rxml><if sizeof="var.basun">1</if></rxml> <result></result> </test> <test> <rxml><set variable="var.basun">abc</set><if sizeof="var.basun == 3">7</if></rxml> <result>7</result> </test> <test> <rxml><set variable="var.basun">abc</set><if sizeof="var.basun == 4">7</if></rxml> <result></result> </test> <test> <rxml><set variable="var.x">A</set><if variable="var.x == a">1</if></rxml> <result>1</result> </test> <test> <rxml><set variable="var.x">A</set><if Variable="var.x == A">1</if></rxml> <result>1</result> </test> <test> <rxml><set variable="var.x">A</set><if Variable="var.x == a">1</if></rxml> <result></result> </test>
9dc8ef2001-04-21Martin Nilsson  <test> <add what="request_header" name="accept" value="image/gif, image/jpeg"/> <rxml><if accept="image/jpeg">1</if></rxml> <result>1</result> </test> <test> <add what="request_header" name="accept" value="audio/mpeg, image/jpeg"/> <rxml><if accept="image/*">1</if></rxml> <result>1</result> </test> <test> <add what="request_header" name="accept" value="audio/mpeg, image/jpeg"/> <rxml><if accept="text/plain">1</if></rxml> <result></result>
9057062001-01-30Martin Nilsson </test>
50644b2001-06-21Martin Nilsson  <test> <rxml><set variable="var.date"><date strftime="%Y%m%d"/></set><if date="&var.date;" after="1">X</if>Y</rxml> <result>Y</result> </test> <test> <rxml><set variable="var.date"><date strftime="%Y%m%d"/></set><if date="&var.date;" after="1" inclusive="1">&var.date;X</if>Y</rxml> <result>XY</result> </test> <test> <rxml><set variable="var.date"><date strftime="%Y%m%d"/></set><if date="&var.date;" before="1">&var.date;X</if>Y</rxml> <result>Y</result> </test> <test> <rxml><set variable="var.date"><date strftime="%Y%m%d"/></set><if date="&var.date;" before="1" inclusive="1">&var.date;X</if>Y</rxml> <result>XY</result> </test> <test> <rxml><set variable="var.date"><date strftime="%Y%m%d" days="-1"/></set><if date="&var.date;" after="1">&var.date;X</if>Y</rxml> <result>XY</result> </test> <test> <rxml><set variable="var.date"><date strftime="%Y%m%d" days="1"/></set><if date="&var.date;" before="1">&var.date;X</if>Y</rxml> <result>XY</result> </test>
a5425f2001-06-22Martin Nilsson  <test> <rxml><set variable="var.time"><date strftime="%H%M"/></set><if time="&var.time;" after="1">&var.time;X</if>Y</rxml> <result>Y</result> </test> <test> <rxml><set variable="var.time"><date strftime="%H%M"/></set><if time="&var.time;" after="1" inclusive="1">&var.time;X</if>Y</rxml> <result>XY</result> </test> <test> <rxml><set variable="var.time"><date strftime="%H%M"/></set><if time="&var.time;" before="1">&var.time;X</if>Y</rxml> <result>Y</result> </test> <test> <rxml><set variable="var.time"><date strftime="%H%M"/></set><if time="&var.time;" before="1" inclusive="1">&var.time;X</if>Y</rxml> <result>XY</result> </test> <test> <rxml><set variable="var.time"><date strftime="%H%M" minutes="-1"/></set><if time="&var.time;" after="1">&var.time;X</if>Y</rxml> <result>XY</result> </test> <test> <rxml><set variable="var.time"><date strftime="%H%M" minutes="1"/></set><if time="&var.time;" before="1">&var.time;X</if>Y</rxml> <result>XY</result> </test>
9057062001-01-30Martin Nilsson  <comment>Missing test: if user</comment> <comment>Missing test: if group</comment> <comment>Missing test: if accept</comment> <comment>Missing test: if config</comment> <comment>Missing test: if cookie</comment> <comment>Missing test: if client</comment> <comment>Missing test: if defined</comment> <comment>Missing test: if domain</comment> <comment>Missing test: if ip</comment> <comment>Missing test: if language</comment> <comment>Missing test: if pragma</comment> <comment>Missing test: if prestate</comment> <comment>Missing test: if referrer</comment> <comment>Missing test: if supports</comment> <comment>Missing test: if clientvar</comment>
9dc8ef2001-04-21Martin Nilsson <comment>Missing test: <cond></comment> <!-- ............................................................ --> <comment>Path emit plugin</comment> <test> <rxml><emit source="path" path="/a/b/c">&_.name; &_.path;|</emit></rxml> <result> /|a /a|b /a/b|c /a/b/c|</result> </test> <test> <rxml><emit source="path" path="/a/b/c" trim="/c">&_.name; &_.path;|</emit></rxml> <result> /|a /a|b /a/b|</result> </test> <test> <rxml><emit source="path" path="/a/b/c" skip="1">&_.name; &_.path;|</emit></rxml> <result>a /a|b /a/b|c /a/b/c|</result> </test> <test> <rxml><emit source="path" path="/a/b/c" skip-end="1">&_.name; &_.path;|</emit></rxml> <result> /|a /a|b /a/b|</result>
9057062001-01-30Martin Nilsson </test>
5a1b8a2001-03-24Martin Nilsson 
cdece02001-01-29Per Hedbor <!-- ............................................................ --> <comment>Emit tests</comment> <test> <rxml><emit source="values" values="1,2,3" split=",">&_.value;:</emit></rxml> <result>1:2:3:</result> </test>
ed33482001-03-15Martin Nilsson  <test> <rxml><emit source="OTESTER">&_.c;:</emit></rxml> <result>1:2:3:4:</result> </test>
cdece02001-01-29Per Hedbor  <test> <rxml><emit source="values" values="a&#0;b">&#0;&_.value;:</emit></rxml> <result>a:b:</result> </test> <test> <rxml><emit split="," source="values" values="a,b,c">&_.value;<emit split="," source="values" values="1,2,3">&_.value;<delimiter>:</delimiter ></emit><delimiter>-</delimiter></emit></rxml> <result>a1:2:3-b1:2:3-c1:2:3</result> </test>
ed33482001-03-15Martin Nilsson  <test> <rxml><emit source="OTESTER">&_.c;<emit source="OTESTER">&_.c;<delimiter>:</delimiter ></emit><delimiter>-</delimiter></emit></rxml> <result>11:2:3:4-21:2:3:4-31:2:3:4-41:2:3:4</result> </test>
cdece02001-01-29Per Hedbor  <test> <rxml><emit source="values" values="a.b.c" split=".">&_.value;&_.counter;</emit></rxml> <result>a1b2c3</result> </test>
ed33482001-03-15Martin Nilsson  <test> <rxml><emit source="OTESTER">&_.c;&_.counter;</emit></rxml> <result>11223344</result> </test>
cdece02001-01-29Per Hedbor  <test> <rxml><emit source="values" values="a.b.c" split="." do-once="1">&_.value;:</emit></rxml> <result>a:b:c:</result> </test>
ed33482001-03-15Martin Nilsson  <test> <rxml><emit source="OTESTER">&_.c;:</emit></rxml> <result>1:2:3:4:</result> </test>
cdece02001-01-29Per Hedbor  <test> <rxml><emit source="values" values="abcdefgh" split="" maxrows="4">&_.value; </emit></rxml> <result>a b c d </result> </test>
ed33482001-03-15Martin Nilsson  <test> <rxml><emit source="OTESTER" test="2" maxrows="4">&_.data; </emit></rxml> <result>aa a aa a </result> </test>
cdece02001-01-29Per Hedbor  <test> <rxml><emit source="values" values="a,b,c" split="," maxrows="100">&_.value; </emit></rxml> <result>a b c </result> </test>
ed33482001-03-15Martin Nilsson  <test> <rxml><emit source="OTESTER" maxrows="100">&_.c; </emit></rxml> <result>1 2 3 4 </result> </test>
cdece02001-01-29Per Hedbor  <test> <rxml><emit source="values" values="a,b,c" split="," skiprows="100">&_.value;:</emit></rxml> <result></result> </test>
ed33482001-03-15Martin Nilsson  <test> <rxml><emit source="OTESTER" skiprows="100">&_.c;:</emit></rxml> <result></result> </test>
cdece02001-01-29Per Hedbor  <test> <rxml><emit source="values" values="a,b,c" split="," skiprows="100" do-once="1">&_.value;:</emit></rxml> <result>:</result> </test>
ed33482001-03-15Martin Nilsson  <test> <rxml><emit source="OTESTER" skiprows="100" do-once="1">&_.c;:</emit></rxml> <result>:</result> </test>
53c3162001-02-19Martin Nilsson  <test> <rxml><emit source="values" values="a,b,c" split="," skiprows="0">&_.value;</emit></rxml> <result>abc</result> </test>
ed33482001-03-15Martin Nilsson  <test> <rxml><emit source="OTESTER" skiprows="0">&_.c;</emit></rxml> <result>1234</result> </test>
53c3162001-02-19Martin Nilsson  <test> <rxml><emit source="values" values="a,b,c" split="," skiprows="-2">&_.value;</emit></rxml> <result>bc</result> </test>
ed33482001-03-15Martin Nilsson <test> <rxml><emit source="OTESTER" skiprows="-3">&_.c;</emit></rxml>
53c3162001-02-19Martin Nilsson <result>234</result> </test>
cdece02001-01-29Per Hedbor  <test> <rxml><emit source="values" values="a,b,c,d,e" split="," skiprows="2">&_.value; </emit></rxml> <result>c d e </result> </test>
ed33482001-03-15Martin Nilsson  <test> <rxml><emit source="OTESTER" skiprows="2">&_.c; </emit></rxml> <result>3 4 </result> </test>
cdece02001-01-29Per Hedbor  <test> <rxml><emit source="values" values="a.b.c.d.e.f.g" split="." skiprows="2" maxrows="2" remainderinfo="var.rem">&_.value; </emit>&var.rem;</rxml> <result>c d 3</result> </test>
ce72d42001-06-01Martin Nilsson  <test> <rxml><emit source="TESTER" remainderinfo="var.rem">&_.c;:</emit>&var.rem;</rxml> <result>1:2:3:4:0</result> </test>
ed33482001-03-15Martin Nilsson  <test> <rxml><emit source="OTESTER" test="2" skiprows="3" maxrows="2" remainderinfo="var.rem">&_.data; </emit>&var.rem;</rxml> <result>a bb 14</result> </test>
cdece02001-01-29Per Hedbor  <test> <rxml><set variable="var.txt">1 2 3 4 5</set><emit source="values" values="&var.txt;" advanced="lines">&var.txt;&_.value;:</emit></rxml> <result>1:2:3:4:5:</result> </test> <test> <rxml><emit source="TESTER" sort="d">&_.c;:</emit></rxml> <result>4:3:1:2:</result> </test>
ed33482001-03-15Martin Nilsson  <test> <rxml><emit source="OTESTER" sort="d">&_.c;:</emit></rxml> <result>4:3:1:2:</result> </test>
cdece02001-01-29Per Hedbor  <test> <rxml><emit source="TESTER" sort="+d">&_.c;:</emit></rxml> <result>4:3:1:2:</result> </test>
ed33482001-03-15Martin Nilsson  <test> <rxml><emit source="OTESTER" sort="+d">&_.c;:</emit></rxml> <result>4:3:1:2:</result> </test>
cdece02001-01-29Per Hedbor  <test> <rxml><emit source="TESTER" sort="-d">&_.c;:</emit></rxml> <result>2:1:3:4:</result> </test>
ed33482001-03-15Martin Nilsson  <test> <rxml><emit source="OTESTER" sort="-d">&_.c;:</emit></rxml> <result>2:1:3:4:</result> </test>
cdece02001-01-29Per Hedbor  <test> <rxml><emit source="TESTER" sort="a,d">&_.c;:</emit></rxml> <result>1:2:4:3:</result> </test>
ed33482001-03-15Martin Nilsson  <test> <rxml><emit source="OTESTER" sort="a,d">&_.c;:</emit></rxml> <result>1:2:4:3:</result> </test>
cdece02001-01-29Per Hedbor  <test> <rxml><emit source="TESTER" sort="a,-d">&_.c;:</emit></rxml> <result>2:1:4:3:</result> </test>
ed33482001-03-15Martin Nilsson  <test> <rxml><emit source="OTESTER" sort="a,-d">&_.c;:</emit></rxml> <result>2:1:4:3:</result> </test>
cdece02001-01-29Per Hedbor  <test> <rxml><emit source="TESTER" sort="b">&_.c;:</emit></rxml> <result>4:2:1:3:</result> </test>
ed33482001-03-15Martin Nilsson  <test> <rxml><emit source="OTESTER" sort="b">&_.c;:</emit></rxml> <result>4:2:1:3:</result> </test>
2d8cdf2001-06-11Martin Nilsson 
50644b2001-06-21Martin Nilsson <test> <rxml><emit source="TESTER" test="3" sort="data"><set variable="x">1</set>&_.data;:</emit></rxml>
2d8cdf2001-06-11Martin Nilsson <result>:0:a:</result> </test>
cdece02001-01-29Per Hedbor  <test> <rxml><emit source="TESTER" sort="c" filter="a=??x">&_.c;:</emit></rxml> <result>1:2:4:</result> </test>
ed33482001-03-15Martin Nilsson  <test> <rxml><emit source="OTESTER" sort="c" filter="a=??x">&_.c;:</emit></rxml> <result>1:2:4:</result> </test>
cdece02001-01-29Per Hedbor  <test> <rxml><emit source="TESTER" sort="c" filter="a=??x, b=**o">&_.c;:</emit></rxml> <result>1:2:</result> </test>
ed33482001-03-15Martin Nilsson  <test> <rxml><emit source="OTESTER" sort="c" filter="a=??x, b=**o">&_.c;:</emit></rxml> <result>1:2:</result> </test>
cdece02001-01-29Per Hedbor  <test> <rxml><emit source="TESTER" sort="c" filter="a=??x,b=*">&_.c;:</emit></rxml> <result>1:2:4:</result> </test>
ed33482001-03-15Martin Nilsson  <test> <rxml><emit source="OTESTER" sort="c" filter="a=??x,b=*">&_.c;:</emit></rxml> <result>1:2:4:</result> </test>
cdece02001-01-29Per Hedbor  <test> <rxml><emit source="TESTER" sort="c" filter="a=??x" do-once="1">&_.c;:</emit></rxml> <result>1:2:4:</result> </test>
ed33482001-03-15Martin Nilsson  <test> <rxml><emit source="OTESTER" sort="c" filter="a=??x" do-once="1">&_.c;:</emit></rxml> <result>1:2:4:</result> </test>
cdece02001-01-29Per Hedbor  <test> <rxml><emit source="TESTER" sort="c" filter="a=??y" do-once="1">&_.c;:</emit></rxml> <result>:</result> </test>
ed33482001-03-15Martin Nilsson  <test> <rxml><emit source="OTESTER" sort="c" filter="a=??y" do-once="1">&_.c;:</emit></rxml> <result>:</result> </test>
cdece02001-01-29Per Hedbor  <test> <rxml><emit source="TESTER" sort="-b" filter="a=??x" skiprows="1">&_.c;:</emit></rxml> <result>2:4:</result> </test>
ed33482001-03-15Martin Nilsson  <test> <rxml><emit source="OTESTER" sort="-b" filter="a=??x" skiprows="1">&_.c;:</emit></rxml> <result>2:4:</result> </test>
cdece02001-01-29Per Hedbor  <test> <rxml><emit source="TESTER" sort="c" filter="a=??x" maxrows="2">&_.c;:</emit></rxml> <result>1:2:</result> </test>
ed33482001-03-15Martin Nilsson  <test> <rxml><emit source="OTESTER" sort="c" filter="a=??x" maxrows="2">&_.c;:</emit></rxml> <result>1:2:</result> </test>
cdece02001-01-29Per Hedbor  <test> <rxml><emit source="TESTER" sort="c" filter="a=??x" maxrows="2" remainderinfo="var.rem">&_.c;:</emit>&var.rem;</rxml> <result>1:2:1</result> </test>
ed33482001-03-15Martin Nilsson  <test> <rxml><emit source="OTESTER" sort="c" filter="a=??x" maxrows="2" remainderinfo="var.rem">&_.c;:</emit>&var.rem;</rxml> <result>1:2:1</result> </test>
ce72d42001-06-01Martin Nilsson  <test> <rxml><emit source="OTESTER" remainderinfo="var.rem">&_.c;:</emit>&var.rem;</rxml> <result>1:2:3:4:0</result> </test>
cdece02001-01-29Per Hedbor  <test> <rxml><emit source="TESTER" sort="-b" filter="a=??x" skiprows="100">&_.c;:</emit></rxml> <result></result> </test>
ed33482001-03-15Martin Nilsson  <test> <rxml><emit source="OTESTER" sort="-b" filter="a=??x" skiprows="100">&_.c;:</emit></rxml> <result></result> </test>
cdece02001-01-29Per Hedbor  <test> <rxml><emit source="TESTER" sort="c" filter="a=??x" maxrows="100">&_.c;:</emit></rxml> <result>1:2:4:</result> </test>
ed33482001-03-15Martin Nilsson  <test> <rxml><emit source="OTESTER" sort="c" filter="a=??x" maxrows="100">&_.c;:</emit></rxml> <result>1:2:4:</result> </test>
cdece02001-01-29Per Hedbor  <test> <rxml><emit source="TESTER" sort="c" filter="a=??x" rowinfo="var.row">&_.c;:</emit>&var.row;</rxml> <result>1:2:4:3</result> </test>
ed33482001-03-15Martin Nilsson  <test> <rxml><emit source="OTESTER" sort="c" filter="a=??x" rowinfo="var.row">&_.c;:</emit>&var.row;</rxml> <result>1:2:4:3</result> </test>
53c3162001-02-19Martin Nilsson 
dfa8b92001-06-08Martin Nilsson <test> <rxml><emit source="TESTER" sort="c" filter="a=basun" rowinfo="var.row" do-once="1">&_.counter;,&_.c;:</emit>&var.row;</rxml>
53c3162001-02-19Martin Nilsson <result>1,:0</result> </test>
ed33482001-03-15Martin Nilsson 
dfa8b92001-06-08Martin Nilsson <test> <rxml><emit source="OTESTER" sort="c" filter="a=basun" rowinfo="var.row" do-once="1">&_.counter;,&_.c;:</emit>&var.row;</rxml>
ed33482001-03-15Martin Nilsson <result>1,:0</result> </test>
cdece02001-01-29Per Hedbor  <test> <rxml><emit source="TESTER" test="2" filter="data=?">&_.data;:</emit></rxml> <result>a:a:b:c:a:d:e:a:a:a:</result> </test>
ed33482001-03-15Martin Nilsson  <test> <rxml><emit source="OTESTER" test="2" filter="data=?">&_.data;:</emit></rxml> <result>a:a:b:c:a:d:e:a:a:a:</result> </test>
cdece02001-01-29Per Hedbor  <test> <rxml><emit source="TESTER" test="2" filter="data=?" skiprows="3" maxrows="5">&_.data;:</emit></rxml> <result>c:a:d:e:a:</result> </test>
ed33482001-03-15Martin Nilsson  <test> <rxml><emit source="OTESTER" test="2" filter="data=?" skiprows="3" maxrows="5">&_.data;:</emit></rxml> <result>c:a:d:e:a:</result> </test>
cdece02001-01-29Per Hedbor  <test> <rxml><emit source="TESTER" test="2" filter="data=?">&_.data;<delimiter>:</delimiter></emit></rxml> <result>a:a:b:c:a:d:e:a:a:a</result> </test>
ed33482001-03-15Martin Nilsson  <test> <rxml><emit source="OTESTER" test="2" filter="data=?">&_.data;<delimiter>:</delimiter></emit></rxml> <result>a:a:b:c:a:d:e:a:a:a</result> </test>
cdece02001-01-29Per Hedbor  <test> <rxml><emit source="TESTER" test="2" filter="data=?" skiprows="3">&_.data;<delimiter>:</delimiter></emit></rxml> <result>c:a:d:e:a:a:a</result> </test>
ed33482001-03-15Martin Nilsson  <test> <rxml><emit source="OTESTER" test="2" filter="data=?" skiprows="3">&_.data;<delimiter>:</delimiter></emit></rxml> <result>c:a:d:e:a:a:a</result> </test>
cdece02001-01-29Per Hedbor  <test> <rxml><emit source="TESTER" test="2" filter="data=?" skiprows="3" maxrows="5">&_.data;<delimiter>:</delimiter></emit></rxml> <result>c:a:d:e:a</result> </test>
ed33482001-03-15Martin Nilsson  <test> <rxml><emit source="OTESTER" test="2" filter="data=?" skiprows="3" maxrows="5">&_.data;<delimiter>:</delimiter></emit></rxml> <result>c:a:d:e:a</result> </test>
53c3162001-02-19Martin Nilsson  <test> <rxml><true/><emit source="values" values="a" filter="value=c">.</emit><then>a</then><else>b</else></rxml> <result>b</result> </test>
ed33482001-03-15Martin Nilsson  <test> <rxml><true/><emit source="OTESTER" test="2" filter="data=x" >.</emit><then>a</then><else>b</else></rxml> <result>b</result> </test>
53c3162001-02-19Martin Nilsson  <test> <rxml><true/><emit source="values" values="a">.</emit><then>a</then><else>b</else></rxml> <result>.a</result> </test>
ed33482001-03-15Martin Nilsson  <test> <rxml><true/><emit source="OTESTER" test="2" filter="data=e" >.</emit><then>a</then><else>b</else></rxml> <result>.a</result> </test>
816b012001-04-02Martin Nilsson 
50644b2001-06-21Martin Nilsson <test>
816b012001-04-02Martin Nilsson <rxml><emit source="TESTER" test="3"><set variable="x">1</set>&_.data;&_.data;,</emit></rxml> <result>aa,,01,</result> </test>
50644b2001-06-21Martin Nilsson <test><!-- make sure the emit source is resetted -->
816b012001-04-02Martin Nilsson <rxml><emit source="TESTER" test="3"><set variable="x">1</set>&_.data;&_.data;,</emit></rxml> <result>aa,,01,</result> </test>
50644b2001-06-21Martin Nilsson <test>
816b012001-04-02Martin Nilsson <rxml><emit source="OTESTER" test="3"><set variable="x">1</set>&_.data;&_.data;,</emit></rxml> <result>aa,,01,</result> </test>
50644b2001-06-21Martin Nilsson <test><!-- make sure the emit source is resetted -->
816b012001-04-02Martin Nilsson <rxml><emit source="OTESTER" test="3"><set variable="x">1</set>&_.data;&_.data;,</emit></rxml> <result>aa,,01,</result> </test>
9011e92001-04-08Martin Nilsson  <test> <rxml><emit source="TESTER" test="4">&_.a; &_.b; &_.c;<delimiter>,</delimiter></emit></rxml> <result>1 aa ca,2 ba cb,3 ab ba</result> </test>
6d5e122001-04-08Martin Nilsson  <test> <rxml><emit source="OTESTER" test="4">&_.a; &_.b; &_.c;<delimiter>,</delimiter></emit></rxml> <result>1 aa ca,2 ba cb,3 ab ba</result> </test>
9011e92001-04-08Martin Nilsson  <test> <rxml><emit source="TESTER" test="4" filter="b=a*">&_.a;</emit></rxml> <result>13</result> </test>
6d5e122001-04-08Martin Nilsson  <test> <rxml><emit source="OTESTER" test="4" filter="b=a*">&_.a;</emit></rxml> <result>13</result> </test>
9011e92001-04-08Martin Nilsson  <test> <rxml><emit source="TESTER" test="4" filter="c=c*">&_.a;</emit></rxml> <result>12</result> </test>
6d5e122001-04-08Martin Nilsson  <test> <rxml><emit source="OTESTER" test="4" filter="c=c*">&_.a;</emit></rxml> <result>12</result> </test>
9011e92001-04-08Martin Nilsson  <test> <rxml><emit source="TESTER" test="4" sort="b">&_.a;</emit></rxml> <result>132</result> </test>
6d5e122001-04-08Martin Nilsson  <test> <rxml><emit source="OTESTER" test="4" sort="b">&_.a;</emit></rxml> <result>132</result> </test>
9011e92001-04-08Martin Nilsson  <test> <rxml><emit source="TESTER" test="4" sort="c">&_.a;</emit></rxml> <result>312</result> </test>
6d5e122001-04-08Martin Nilsson  <test> <rxml><emit source="OTESTER" test="4" sort="c">&_.a;</emit></rxml> <result>312</result> </test>
61ed2c2001-05-31Martin Nilsson  <test> <rxml><emit source="STESTER">&_.c;</emit></rxml> <result>1234</result> </test> <test> <rxml><emit source="STESTER" skiprows="2">&_.c;</emit></rxml> <result>1234</result> </test> <test> <rxml><emit source="STESTER" maxrows="2">&_.c;</emit></rxml> <result>1234</result> </test> <test> <rxml><emit source="STESTER" sort="d">&_.c;</emit></rxml> <result>1234</result> </test> <test> <rxml><emit source="STESTER" sort="d" skiprows="2" maxrows="1">&_.c;</emit></rxml> <result>1234</result> </test>
ce72d42001-06-01Martin Nilsson  <test> <rxml>&var.rem;<emit source="STESTER" remainderinfo="var.rem">&_.c;:</emit>&var.rem;</rxml> <result>1:2:3:4:0</result> </test>
ed33482001-03-15Martin Nilsson 
fdf7762001-05-31Martin Nilsson  <!-- ............................................................ --> <comment>Values emit plugin</comment> <test> <rxml><set variable="var.foo">1</set><set variable="var.bar">2</set><emit source="values" from-scope="var" sort="index">&_.index;=&_.value; </emit></rxml> <result>bar=2 foo=1 </result> </test> <test> <add what="rvariable" name="x" value="a,b,c" split="," /> <rxml><emit source="values" variable="form.x">&_.value; </emit></rxml> <result>a b c </result> </test> <test> <rxml><set variable="var.a">aa</set><set variable="var.b">AA</set><emit source="values" from-scope="var" case="lower">&_.value; </emit></rxml> <result>aa aa </result> </test> <test> <rxml><set variable="var.a">aa</set><set variable="var.b">AA</set><emit source="values" from-scope="var" case="upper">&_.value; </emit></rxml> <result>AA AA </result> </test> <test> <rxml><set variable="var.a"> a </set><set variable="var.b">b </set><emit source="values" from-scope="var" trimwhites="1">&_.value; </emit></rxml> <result>a b </result> </test> <test> <rxml><emit source="values" values="a,b,c" split=",">&_.value; </emit></rxml> <result>a b c </result> </test> <test> <rxml><set variable="var.x">a&#0;b&#0;c</set><emit source="values" values="&var.x;">&var.x;&_.value; </emit></rxml> <result>a b c </result> </test> <test> <rxml><emit source="values" values="hello" advanced="chars">&_.value; </emit></rxml> <result>h e l l o </result> </test> <test> <rxml><set variable="var.x">1 2 3</set><emit source="values" values="&var.x;" advanced="lines">&var.x;&_.value; </emit></rxml> <result>1 2 3 </result> </test> <test> <rxml><set variable="var.x">This will demon- strate things. What? Hi, ho! Blaha boo</set><emit source="values" values="&var.x;" advanced="words">&var.x;&_.value; </emit></rxml> <result>This will demonstrate things What Hi ho Blaha boo </result> </test> <test> <rxml><emit source="values" values="aa,AA,aA,Aa" split="," case="upper">&_.value; </emit></rxml> <result>AA AA AA AA </result> </test> <test> <rxml><emit source="values" values="aa,AA,aA,Aa" split="," case="lower">&_.value; </emit></rxml> <result>aa aa aa aa </result> </test> <test> <rxml><emit source="values" values=" a , b,c " split="," trimwhites="1">&_.value; </emit></rxml> <result>a b c </result>
cdece02001-01-29Per Hedbor </test>
5a1b8a2001-03-24Martin Nilsson 
cdece02001-01-29Per Hedbor <!-- ............................................................ --> <comment>Use tests</comment> <test> <rxml><use package="test_rxml_package"/><bä/></rxml> <result>Mu!</result> </test> <test> <rxml><use package="test_rxml_package"/>< x="Boo"/></rxml> <result>Boo!</result> </test> <test> <rxml><use package="test_rxml_package"/><gazonkx/></rxml> <resultat><gazonkx/></resultat> </test> <test> <rxml><use package="test_rxml_package"/><bold>x</bold></rxml> <result><b>x</b></result> </test> <test> <rxml><use package="test_rxml_package"/><italic>y</italic></rxml> <result><italic>y</italic></result> </test> <test> <rxml><use package="test_rxml_package"/>&var.a;</rxml> <result>AA</result> </test> <test> <rxml><use package="test_rxml_package"/>&var.b;.</rxml> <result>.</result> </test> <test> <rxml><if rxml_test="xyz">1</if><use package="test_rxml_package"/><if rxml_test="xyz">2</if><if rxml_test="a">3</if></rxml> <result>2</result> </test> <test> <rxml><if rxml_test2="abc">1</if><use package="test_rxml_package"/><if rxml_test2="abc">2</if><if rxml_test2="a">3</if></rxml> <result></result> </test> <test> <rxml><use packageinfo="1"/></rxml> <has-value>roxenlogo</has-value> <has-value>test_rxml_package</has-value> <has-value>RXML test package</has-value> </test> <test> <rxml><use package="test_rxml_package" info="1"/></rxml> <has-value not="1">roxenlogo</has-value> <has-value>test_rxml_package</has-value> <has-value>RXML test package</has-value> </test> <comment>Missing test: load package from file</comment>
9dc8ef2001-04-21Martin Nilsson  <!-- ............................................................ --> <comment>RXML help</comment> <test> <rxml><help/></rxml> <glob>*</glob>
cdece02001-01-29Per Hedbor </test>
5a1b8a2001-03-24Martin Nilsson 
cdece02001-01-29Per Hedbor <!-- ............................................................ --> <comment>Number tests</comment> <test> <rxml><number num="3"/></rxml> <result>three</result> </test> <test> <rxml><number type="number" num="3"/></rxml> <result>three</result> </test> <test> <rxml><number type="roman" num="3"/></rxml> <result>III</result> </test> <test> <rxml><number type="memory" num="14588"/></rxml> <result>14.2 kb</result> </test> <test> <rxml><number num="3" language="sv"/></rxml> <result>tre</result> </test> <test> <rxml><number num="3" language="swe"/></rxml> <result>tre</result> </test> <test> <rxml><number type="ordered" num="3"/></rxml> <result>3rd</result> </test> <test> <rxml><number type="ordered" num="3" language="swe"/></rxml> <result>3:e</result> </test>
5a1b8a2001-03-24Martin Nilsson 
cdece02001-01-29Per Hedbor <!-- ............................................................ --> <comment>Noparse/eval/nooutput tests</comment> <test> <rxml><noparse><roxen/></noparse></rxml> <result><roxen/></result> </test> <test> <rxml><?noparse <roxen/>?></rxml> <result><roxen/></result> </test> <test> <rxml><?cdata <roxen/>?></rxml> <result>&lt;roxen/&gt;</result> </test> <test> <rxml><define variable="var.x">&var.y;</define><set variable="var.y">Q</set><eval>&var.x:none;</eval></rxml> <result>Q</result> </test> <test> <rxml><nooutput><set variable="var.i">x</set>y</nooutput>z&var.i;</rxml> <result>zx</result> </test>
5a1b8a2001-03-24Martin Nilsson 
cdece02001-01-29Per Hedbor <!-- ............................................................ --> <comment>Strlen tests</comment> <test> <rxml><strlen/></rxml> <result>0</result> </test> <test> <rxml><strlen></strlen></rxml> <result>0</result> </test> <test> <rxml><strlen>ab cd</rxml> <result>5</result>
9057062001-01-30Martin Nilsson </test>
5a1b8a2001-03-24Martin Nilsson 
9057062001-01-30Martin Nilsson <!-- ............................................................ --> <comment>Entity tests</comment> <test>
5bda532001-04-19Martin Nilsson <rxml><set variable="var.x">&amp;</set>&var.x;</rxml>
9057062001-01-30Martin Nilsson <result>&amp;</result> </test> <test> <rxml><set variable="var.x" value="&amp;"/>&amp;&var.x;</rxml> <result>&amp;</result> </test> <test> <rxml><set variable="var.x" value="&amp;"/>&amp;&var.x:none;</rxml> <result>&</result>
654d2c2001-03-23Per Hedbor </test>
72cb2e2001-04-21Martin Nilsson  <comment>Quoting tests missing</comment>
5a1b8a2001-03-24Martin Nilsson  <!-- ............................................................ -->
654d2c2001-03-23Per Hedbor <comment>Form scope</comment> <test> <rxml>&form.no-such-variable;</rxml> <result></result> </test>
72cb2e2001-04-21Martin Nilsson  <test> <rxml><set variable="form.foo" value="a,b" split=","/>&form.foo;</rxml> <glob>a&#0;b</glob> </test> <test> <rxml><set variable="form.foo" value="x"/>&form.foo;</rxml> <result>x</result> </test> <test> <add what="variable" name="bar" value="q"/> <rxml>&form.bar;</rxml> <result>q</result> </test> <!-- Ensuring id->variables integrity --> <test> <rxml>&form.bar;</rxml> <result></result> </test> <test> <add what="rvariable" name="bar" value="r"/> <rxml>&form.bar;</rxml> <result>r</result> </test> <!-- Ensuring id->real_variables integrity --> <test> <rxml>&form.bar;</rxml> <result></result> </test> <test> <rxml><set variable="form.x" value="y"/>&form.x.1;</rxml> <result>y</result> </test> <test> <add what="rvariable" name="bar" value="s,t" split=","/> <rxml>&form.bar; &form.bar.1; &form.bar.2;</rxml> <result>s&#0;t s t</result> </test> <!-- Should fail <test> <add what="rvariable" name="bar" value="s,t"/> <rxml>&form.bar.2;</rxml> </test> -->
5a1b8a2001-03-24Martin Nilsson  <test> <rxml><insert variables="full" scope="form"/> Checking for backtrace</rxml> <glob>*</glob> </test> <!-- ............................................................ -->
654d2c2001-03-23Per Hedbor <comment>Var scope</comment> <test> <rxml>&var.no-such-variable;</rxml> <result></result> </test>
72cb2e2001-04-21Martin Nilsson  <test> <rxml><set variable="var.foo" value="bork"/>&var.foo;</rxml> <result>bork</result> </test>
5a1b8a2001-03-24Martin Nilsson  <test> <rxml><insert variables="full" scope="var"/> Checking for backtrace</rxml> <glob>*</glob> </test> <!-- ............................................................ -->
654d2c2001-03-23Per Hedbor <comment>Page scope</comment> <test> <rxml>&page.no-such-variable;</rxml> <result></result> </test>
72cb2e2001-04-21Martin Nilsson  <test> <rxml>&page.pathinfo;</rxml> <result></result> </test> <test> <add what="misc" name="path_info" value="blarg"/> <rxml>&page.pathinfo;</rxml> <result>blarg</result> </test> <test>
8a17882001-06-09Martin Nilsson <rxml>&page.realfile;</rxml>
72cb2e2001-04-21Martin Nilsson <result>etc/test/filesystem/index.html</result> </test> <!-- This should probably be initialized also --> <test> <rxml>&page.virtroot;</rxml> <result></result> </test> <test> <rxml>&page.virtfile;</rxml> <result>/index.html</result> </test> <test> <rxml>&page.path;</rxml> <result>/index.html</result> </test> <!-- This should probably be initialized also --> <test> <rxml>&page.query;</rxml> <result></result> </test> <test> <rxml>&page.url;</rxml> <result>/index.html</result> </test> <test> <rxml>&page.last-true;<false/>&page.last-true;</rxml> <result>10</result> </test> <test> <rxml>&page.language;</rxml> <result></result> </test> <test> <rxml>&page.scope;</rxml> <result></result> </test> <test> <rxml><emit source="values" values="a">&page.scope;</emit></rxml> <result>values</result> </test> <test> <rxml>&page.filesize;</rxml> <result>5</result> </test> <test> <rxml>&page.self;</rxml> <result>index.html</result> </test> <test> <rxml>&page.ssl-strength;</rxml> <result>0</result> </test> <test> <rxml>&page.dir;</rxml> <result>/</result> </test> <test> <add what="not_query" value="/hej/och/hopp.html"/> <rxml>&page.dir;</rxml> <result>/hej/och/</result> </test> <test> <rxml>&page.fgcolor;</rxml> <result></result> </test>
1f32b52001-06-18Martin Stjernholm <test> <rxml type="string"> <define name="fgcolor">#000000</define> &page.fgcolor; </rxml>
72cb2e2001-04-21Martin Nilsson  <result>#000000</result> </test> <test> <rxml>&page.bgcolor;</rxml> <result></result> </test>
1f32b52001-06-18Martin Stjernholm <test> <rxml type="string"> <define name="bgcolor">#ffffff</define> &page.bgcolor; </rxml>
72cb2e2001-04-21Martin Nilsson  <result>#ffffff</result> </test> <test> <rxml>&page.theme-bgcolor;</rxml> <result></result> </test>
1f32b52001-06-18Martin Stjernholm <test> <rxml type="string"> <define name="theme_bgcolor">#ffffaa</define> &page.theme-bgcolor; </rxml>
72cb2e2001-04-21Martin Nilsson  <result>#ffffaa</result> </test> <test> <rxml>&page.theme-fgcolor;</rxml> <result></result> </test>
1f32b52001-06-18Martin Stjernholm <test> <rxml type="string"> <define name="theme_fgcolor">#ff8c00</define> &page.theme-fgcolor; </rxml>
72cb2e2001-04-21Martin Nilsson  <result>#ff8c00</result> </test> <test> <rxml>&page.theme-language;</rxml> <result></result> </test>
1f32b52001-06-18Martin Stjernholm <test> <rxml type="string"> <define name="theme_language">swe</define> &page.theme-language; </rxml>
72cb2e2001-04-21Martin Nilsson  <result>swe</result> </test>
dff9342001-05-30Martin Nilsson  <test> <rxml>&page.counter; &page.counter;</rxml> <result>1 2</result> </test> <test> <rxml>&page.counter; &page.counter;</rxml> <result>1 2</result> </test>
72cb2e2001-04-21Martin Nilsson  <test> <rxml><set variable="var.foo" value="borkason"/>&var.foo;</rxml> <result>borkason</result> </test>
5a1b8a2001-03-24Martin Nilsson  <test> <rxml><insert variables="full" scope="page"/> Checking for backtrace</rxml> <glob>*</glob> </test> <!-- ............................................................ -->
654d2c2001-03-23Per Hedbor <comment>Client scope</comment> <test> <rxml>&client.no-such-variable;</rxml> <result></result> </test>
9dc8ef2001-04-21Martin Nilsson  <test> <rxml><set variable="client.foo" value="x"/>&client.foo;</rxml> <result>x</result> </test>
5a1b8a2001-03-24Martin Nilsson  <test> <rxml><insert variables="full" scope="client"/> Checking for backtrace</rxml> <glob>*</glob> </test> <test> <rxml>&client.fullname;</rxml> <result></result> </test> <test> <rxml>&client.Fullname;</rxml> <result></result> </test> <test> <rxml>&client.accept-language;</rxml> <result></result> </test> <test> <rxml>&client.accept-languages;</rxml> <result></result> </test>
3dc9422001-03-24Martin Nilsson <test>
5a1b8a2001-03-24Martin Nilsson <rxml>&client.authenticated;</rxml> <result>0</result> </test> <test> <rxml>&client.host;</rxml> <result>127.0.0.1</result> </test> <test> <rxml>&client.ip;</rxml> <result>127.0.0.1</result> </test> <test> <rxml>&client.javascript;</rxml> <result></result> </test> <test> <rxml>&client.language;</rxml> <result></result> </test> <test> <rxml>&client.languages;</rxml> <result></result> </test> <test> <rxml>&client.name;</rxml> <result></result> </test> <test> <rxml>&client.password;</rxml> <result></result> </test> <test> <rxml>&client.referrer;</rxml> <result></result> </test> <test> <rxml>&client.tm;</rxml> <result>&lt;TM&gt;</result> </test> <test> <rxml>&client.user;</rxml> <result></result> </test> <!-- ............................................................ -->
654d2c2001-03-23Per Hedbor <comment>Cookie scope</comment> <test> <rxml>&cookie.no-such-cookie;</rxml> <result></result>
5a1b8a2001-03-24Martin Nilsson </test>
9dc8ef2001-04-21Martin Nilsson  <test> <rxml><set variable="cookie.foo" value="x"/>&cookie.foo;</rxml> <result>x</result> </test>
5a1b8a2001-03-24Martin Nilsson  <test> <rxml><insert variables="full" scope="cookie"/> Checking for backtrace</rxml> <glob>*</glob> </test> <!-- ............................................................ --> <comment>Roxen scope</comment> <test> <rxml>&roxen.no-such-variable;</rxml> <result></result> </test>
9dc8ef2001-04-21Martin Nilsson  <!-- Should fail <test> <rxml><set variable="roxen.foo" value="x"/>&roxen.foo;</rxml> <result></result> </test> -->
5a1b8a2001-03-24Martin Nilsson  <test> <rxml><insert variables="full" scope="roxen"/> Checking for backtrace</rxml> <glob>*</glob> </test> <test>
7560ae2001-04-18Martin Nilsson <rxml>&roxen.domain;</rxml>
5a1b8a2001-03-24Martin Nilsson <glob>?*</glob> </test> <test> <rxml>&roxen.hits;</rxml> <regexp>[0-9]+</regexp> </test> <test> <rxml>&roxen.hits-per-minute;</rxml> <regexp>[0-9]+</regexp> </test> <test> <rxml>&roxen.locale;</rxml> <result>eng</result> </test> <test> <rxml>&roxen.path;</rxml> <result></result> </test> <test>
7560ae2001-04-18Martin Nilsson <rxml>&roxen.pike-version;</rxml>
5a1b8a2001-03-24Martin Nilsson <regexp>Pike v7.[2-9] release [0-9]+</regexp> </test> <test> <rxml>&roxen.sent;</rxml> <regexp>[0-9]+</regexp> </test> <test> <rxml>&roxen.sent-kbit-per-second;</rxml> <regexp>[0-9]+\.[0-9]+</regexp> </test> <test> <rxml>&roxen.sent-mb;</rxml> <regexp>[0-9]+\.[0-9]+</regexp> </test> <test> <rxml>&roxen.sent-per-minute;</rxml> <regexp>[0-9]+</regexp> </test> <test>
7560ae2001-04-18Martin Nilsson <rxml>&roxen.server;</rxml>
5a1b8a2001-03-24Martin Nilsson <glob>http://*:17369</glob> </test> <test>
5bda532001-04-19Martin Nilsson <rxml>&roxen.ssl-strength;</rxml>
5a1b8a2001-03-24Martin Nilsson <regexp>0|40|128|168</regexp> </test> <test> <rxml>&roxen.time;</rxml> <regexp>[0-9]+</regexp> </test> <test> <rxml>&roxen.uptime;</rxml> <regexp>[0-9]+</regexp> </test> <test> <rxml>&roxen.uptime-days;</rxml> <regexp>[0-9]+</regexp> </test> <test> <rxml>&roxen.uptime-hours;</rxml> <regexp>[0-9]+</regexp> </test> <test> <rxml>&roxen.uptime-minutes;</rxml> <regexp>[0-9]+</regexp> </test> <test> <rxml>&roxen.version;</rxml> <regexp>Roxen/2\.2\.[0-9]+</regexp>
9dc8ef2001-04-21Martin Nilsson </test> <test> <rxml>&roxen.unique-id;</rxml> <regexp>[0-9A-F]+</regexp>