mirror of
https://github.com/rn10950/RetroZilla.git
synced 2024-11-15 04:00:12 +01:00
747 lines
16 KiB
HTML
747 lines
16 KiB
HTML
|
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN"
|
||
|
"http://www.w3.org/TR/REC-html40/loose.dtd">
|
||
|
<?foo this is a test processing instruction?>
|
||
|
<!-- TransforMiiX Test cases, written by Keith Visco. -->
|
||
|
<HTML>
|
||
|
<HEAD>
|
||
|
<TITLE>TransforMiiX Test Cases</TITLE>
|
||
|
<SCRIPT Language="JavaScript">
|
||
|
|
||
|
// This is a test for properly printing SCRIPT elements
|
||
|
// currently there is a bug, so use xsl:text as a wrapper as I
|
||
|
// have done here
|
||
|
function foo() {
|
||
|
var x = 1;
|
||
|
var y = 2;
|
||
|
return (x < y);
|
||
|
}
|
||
|
//
|
||
|
|
||
|
</SCRIPT>
|
||
|
</HEAD>
|
||
|
<BODY BGColor="#FFFFFF" Text="#000000">
|
||
|
<CENTER>
|
||
|
<FONT COLOR="BLUE" FACE="Arial" SIZE="+1">
|
||
|
<B>Mozilla XSLT</B>
|
||
|
</FONT>
|
||
|
<BR>
|
||
|
<B>Transfor<FONT COLOR="blue">Mii</FONT>X Test Cases</B>
|
||
|
</CENTER>
|
||
|
<P>This document serves to test basic XSL expressions.</P>
|
||
|
<P>
|
||
|
<B>Testing xsl:variable and xsl:copy-of</B>
|
||
|
<BR>
|
||
|
<B>Test:</B><xsl:copy-of select="$product-name"/><BR>
|
||
|
<B>Desired Result:</B>Transfor<FONT COLOR="blue">Mii</FONT>X<BR>
|
||
|
<B>Result:</B>Transfor<FONT COLOR="blue">Mii</FONT>X</P>
|
||
|
<P>
|
||
|
<B>Testing xsl:if</B>
|
||
|
<BR>
|
||
|
<B>Test:</B><xsl:if test="x | y | z">true</xsl:if><BR>
|
||
|
<B>Desired Result:</B>true<BR>
|
||
|
<B>Result:</B>true</P>
|
||
|
<P>
|
||
|
<B>Testing xsl:if</B>
|
||
|
<BR>
|
||
|
<B>Test:</B><xsl:if test="true()">true</xsl:if><BR>
|
||
|
<B>Desired Result:</B>true<BR>
|
||
|
<B>Result:</B>true</P>
|
||
|
<P>
|
||
|
<B>Testing xsl:if</B>
|
||
|
<BR>
|
||
|
<B>Test:</B><xsl:if test="'a'='b'">a equals b</xsl:if><BR>
|
||
|
<B></B><xsl:if test="'a'!='b'">a does not equal b</xsl:if><BR>
|
||
|
<B>Desired Result:</B>a does not equal to b<BR>
|
||
|
<B>Result:</B>a does not equal b</P>
|
||
|
<P>
|
||
|
<B>Testing xsl:if</B>
|
||
|
<BR>
|
||
|
<B>Test:</B><xsl:if test="2+1-3">2+1-3 is true</xsl:if><BR>
|
||
|
<B> </B><xsl:if test="not(2+1-3)">not(2+1-3) is true</xsl:if><BR>
|
||
|
<B>Desired Result:</B>not(2+1-3) is true<BR>
|
||
|
<B>Result:</B>not(2+1-3) is true</P>
|
||
|
<P>
|
||
|
<B>Testing xsl:choose</B>
|
||
|
<BR>
|
||
|
<B>Test:</B>see source<BR>
|
||
|
<B>Desired Result:</B>true<BR>
|
||
|
<B>Result:</B>true</P>
|
||
|
<P>
|
||
|
<B>Testing parent and ancestor ops</B>
|
||
|
<BR>
|
||
|
<B>Test:</B>see source<BR>
|
||
|
<B>Desired Result:</B>true<BR>
|
||
|
<B>Result:</B>true<BR>
|
||
|
</P>
|
||
|
<P>
|
||
|
<B>Testing basic xsl:apply-templates</B>
|
||
|
<BR>
|
||
|
<B>Test:</B><xsl:apply-templates/><BR>
|
||
|
<B>Desired Result:</B>element x, element y, element z<BR>
|
||
|
<B>Result:</B>
|
||
|
|
||
|
,element<B> x</B>
|
||
|
,element<B> y</B>
|
||
|
,element<B> z</B>
|
||
|
|
||
|
|
||
|
</P>
|
||
|
<P>
|
||
|
<B>Testing basic xsl:apply-templates with mode</B>
|
||
|
<BR>
|
||
|
<B>Test:</B><xsl:apply-templates mode="mode-test"/><BR>
|
||
|
<B>Desired Result:</B>x, y, z<BR>
|
||
|
<B>Result:</B>, x, y, z</P>
|
||
|
<P>
|
||
|
<B>Testing predicates</B>
|
||
|
<BR>
|
||
|
<B>Test:</B>see source<BR>
|
||
|
<B>Desired Result:</B>
|
||
|
<B>z</B>
|
||
|
<BR>
|
||
|
<B>Result:</B>
|
||
|
<B>z</B>
|
||
|
</P>
|
||
|
<P>
|
||
|
<B>Testing predicates</B>
|
||
|
<BR>
|
||
|
<B>Test:</B>see source<BR>
|
||
|
<B>Desired Result:</B>
|
||
|
<BR>
|
||
|
<B>Result:</B>
|
||
|
</P>
|
||
|
<P>
|
||
|
<B>Named Template/Call Template</B>
|
||
|
<P>
|
||
|
<B>Test:</B><xsl:call-template name="named-template-test"/><BR>
|
||
|
<B>Desired Result:</B>named template processed with default value!<BR>
|
||
|
<B>Result:</B>named template processed with default value!</P>
|
||
|
<P>
|
||
|
<B>Test:</B>- passing arguments to named templates (see xsl source)<BR>
|
||
|
<B>Desired Result:</B>named template processed with passed value!<BR>
|
||
|
<B>Result:</B>named template processed with passed value!</P>
|
||
|
</P>
|
||
|
<P>
|
||
|
<B>Attribute Value Templates and variables</B>
|
||
|
<BR>
|
||
|
<B>Test:</B>
|
||
|
<UL><xsl:variable name="color">red</xsl:variable><BR><FONT COLOR="{$color}">Red Text</FONT></UL>
|
||
|
<B>Desired Result:</B>
|
||
|
<FONT COLOR="red">Red Text</FONT>
|
||
|
<BR>
|
||
|
<B>Result:</B>
|
||
|
<FONT COLOR="red">Red Text</FONT>
|
||
|
</P>
|
||
|
<HR>
|
||
|
<TABLE>
|
||
|
<TR BGColor="#E0E0FF">
|
||
|
<TD Colspan="2" ALIGN="CENTER">
|
||
|
<B>Axis Identifiers (these should work, I need more test cases though)</B>
|
||
|
</TD>
|
||
|
</TR>
|
||
|
<TR>
|
||
|
<TD VALIGN="TOP">
|
||
|
<B>Test:</B>
|
||
|
</TD>
|
||
|
<TD><xsl:if test="descendant::z">true</xsl:if><BR>
|
||
|
</TD>
|
||
|
</TR>
|
||
|
<TR>
|
||
|
<TD>
|
||
|
<B>Desired Result:</B>
|
||
|
</TD>
|
||
|
<TD>
|
||
|
<FONT COLOR="blue">true</FONT>
|
||
|
<BR>
|
||
|
</TD>
|
||
|
</TR>
|
||
|
<TR>
|
||
|
<TD>
|
||
|
<B>Result:</B>
|
||
|
</TD>
|
||
|
<TD>
|
||
|
<FONT COLOR="blue">true</FONT>
|
||
|
</TD>
|
||
|
</TR>
|
||
|
<TR>
|
||
|
<TD VALIGN="TOP">
|
||
|
<B>Test:</B>
|
||
|
</TD>
|
||
|
<TD><xsl:if test="not(descendant-or-self::no-element)">true</xsl:if><BR>
|
||
|
</TD>
|
||
|
</TR>
|
||
|
<TR>
|
||
|
<TD>
|
||
|
<B>Desired Result:</B>
|
||
|
</TD>
|
||
|
<TD>
|
||
|
<FONT COLOR="blue">true</FONT>
|
||
|
<BR>
|
||
|
</TD>
|
||
|
</TR>
|
||
|
<TR>
|
||
|
<TD>
|
||
|
<B>Result:</B>
|
||
|
</TD>
|
||
|
<TD>
|
||
|
<FONT COLOR="blue">true</FONT>
|
||
|
</TD>
|
||
|
</TR>
|
||
|
</TABLE>
|
||
|
<HR>
|
||
|
<TABLE>
|
||
|
<TR BGColor="#E0E0FF">
|
||
|
<TD Colspan="2" ALIGN="CENTER">
|
||
|
<B>Creating Elements with xsl:element and xsl:attribute</B>
|
||
|
</TD>
|
||
|
</TR>
|
||
|
<TR>
|
||
|
<TD VALIGN="TOP">
|
||
|
<B>Test:</B>
|
||
|
</TD>
|
||
|
<TD><xsl:element name="FONT"><BR><xsl:attribute name="COLOR">blue</xsl:attribute><BR>Passed<BR></xsl:element></TD>
|
||
|
</TR>
|
||
|
<TR>
|
||
|
<TD>
|
||
|
<B>Desired Result:</B>
|
||
|
</TD>
|
||
|
<TD>
|
||
|
<FONT COLOR="blue">Passed</FONT>
|
||
|
<BR>
|
||
|
</TD>
|
||
|
</TR>
|
||
|
<TR>
|
||
|
<TD>
|
||
|
<B>Result:</B>
|
||
|
</TD>
|
||
|
<TD>
|
||
|
<FONT COLOR="blue">Passed</FONT>
|
||
|
</TD>
|
||
|
</TR>
|
||
|
<TR BGCOLOR="#E0E0FF" ALIGN="CENTER">
|
||
|
<TD COLSPAN="2">
|
||
|
<B>Using Attribute Sets</B>
|
||
|
</TD>
|
||
|
</TR>
|
||
|
<TR>
|
||
|
<TD VALIGN="TOP">
|
||
|
<B>Test:</B>
|
||
|
</TD>
|
||
|
<TD><FONT xsl:use-attribute-sets="style1"><BR>Passed<BR></FONT></TD>
|
||
|
</TR>
|
||
|
<TR>
|
||
|
<TD>
|
||
|
<B>Desired Result:</B>
|
||
|
</TD>
|
||
|
<TD>
|
||
|
<FONT COLOR="blue">Passed</FONT>
|
||
|
<BR>
|
||
|
</TD>
|
||
|
</TR>
|
||
|
<TR>
|
||
|
<TD>
|
||
|
<B>Result:</B>
|
||
|
</TD>
|
||
|
<TD>
|
||
|
<FONT COLOR="blue" SIZE="+0">Passed</FONT>
|
||
|
</TD>
|
||
|
</TR>
|
||
|
<TR>
|
||
|
<TD VALIGN="TOP">
|
||
|
<B>Test:</B>
|
||
|
</TD>
|
||
|
<TD><xsl:element name="FONT" use-attribute-sets="style1 style2"><BR>Passed<BR></xsl:element></TD>
|
||
|
</TR>
|
||
|
<TR>
|
||
|
<TD>
|
||
|
<B>Desired Result:</B>
|
||
|
</TD>
|
||
|
<TD>
|
||
|
<FONT COLOR="red">Passed</FONT>
|
||
|
<BR>
|
||
|
</TD>
|
||
|
</TR>
|
||
|
<TR>
|
||
|
<TD>
|
||
|
<B>Result:</B>
|
||
|
</TD>
|
||
|
<TD>
|
||
|
<FONT COLOR="red" SIZE="+0">Passed</FONT>
|
||
|
</TD>
|
||
|
</TR>
|
||
|
</TABLE>
|
||
|
<HR>
|
||
|
<TABLE>
|
||
|
<TR BGColor="#E0E0FF">
|
||
|
<TD Colspan="2" ALIGN="CENTER">
|
||
|
<B>Numbering (only simple numbering currently implemented)</B>
|
||
|
</TD>
|
||
|
</TR>
|
||
|
<TR>
|
||
|
<TD VALIGN="TOP">
|
||
|
<B>Test:</B>
|
||
|
</TD>
|
||
|
<TD><xsl:number value="4"/><BR>
|
||
|
</TD>
|
||
|
</TR>
|
||
|
<TR>
|
||
|
<TD>
|
||
|
<B>Desired Result:</B>
|
||
|
</TD>
|
||
|
<TD>
|
||
|
<FONT COLOR="blue">4</FONT>
|
||
|
<BR>
|
||
|
</TD>
|
||
|
</TR>
|
||
|
<TR>
|
||
|
<TD>
|
||
|
<B>Result:</B>
|
||
|
</TD>
|
||
|
<TD>
|
||
|
<FONT COLOR="blue">4</FONT>
|
||
|
</TD>
|
||
|
</TR>
|
||
|
<TR>
|
||
|
<TD VALIGN="TOP">
|
||
|
<B>Test:</B>
|
||
|
</TD>
|
||
|
<TD>see source<BR>
|
||
|
</TD>
|
||
|
</TR>
|
||
|
<TR>
|
||
|
<TD>
|
||
|
<B>Desired Result:</B>
|
||
|
</TD>
|
||
|
<TD>
|
||
|
<FONT COLOR="blue">1. x<BR>1. y<BR>1. z</FONT>
|
||
|
<BR>
|
||
|
</TD>
|
||
|
</TR>
|
||
|
<TR>
|
||
|
<TD>
|
||
|
<B>Result:</B>
|
||
|
</TD>
|
||
|
<TD>
|
||
|
<FONT COLOR="blue">1. x<BR>1. y<BR>1. z<BR>
|
||
|
</FONT>
|
||
|
</TD>
|
||
|
</TR>
|
||
|
</TABLE>
|
||
|
<HR>
|
||
|
<TABLE>
|
||
|
<TR BGColor="#E0E0FF">
|
||
|
<TD Colspan="2" ALIGN="CENTER">
|
||
|
<B>Additive Expressions</B>
|
||
|
</TD>
|
||
|
</TR>
|
||
|
<TR>
|
||
|
<TD VALIGN="TOP">
|
||
|
<B>Test:</B>
|
||
|
</TD>
|
||
|
<TD><xsl:value-of select="70+4"/><BR>
|
||
|
</TD>
|
||
|
</TR>
|
||
|
<TR>
|
||
|
<TD>
|
||
|
<B>Desired Result:</B>
|
||
|
</TD>
|
||
|
<TD>
|
||
|
<FONT COLOR="blue">74</FONT>
|
||
|
<BR>
|
||
|
</TD>
|
||
|
</TR>
|
||
|
<TR>
|
||
|
<TD>
|
||
|
<B>Result:</B>
|
||
|
</TD>
|
||
|
<TD>
|
||
|
<FONT COLOR="blue">74</FONT>
|
||
|
</TD>
|
||
|
</TR>
|
||
|
<TR>
|
||
|
<TD VALIGN="TOP">
|
||
|
<B>Test:</B>
|
||
|
</TD>
|
||
|
<TD><xsl:value-of select="-70+4"/><BR>
|
||
|
</TD>
|
||
|
</TR>
|
||
|
<TR>
|
||
|
<TD>
|
||
|
<B>Desired Result:</B>
|
||
|
</TD>
|
||
|
<TD>
|
||
|
<FONT COLOR="blue">-66</FONT>
|
||
|
<BR>
|
||
|
</TD>
|
||
|
</TR>
|
||
|
<TR>
|
||
|
<TD>
|
||
|
<B>Result:</B>
|
||
|
</TD>
|
||
|
<TD>
|
||
|
<FONT COLOR="blue">-66</FONT>
|
||
|
</TD>
|
||
|
</TR>
|
||
|
<TR>
|
||
|
<TD VALIGN="TOP">
|
||
|
<B>Test:</B>
|
||
|
</TD>
|
||
|
<TD><xsl:value-of select="1900+70+8-4"/><BR>
|
||
|
</TD>
|
||
|
</TR>
|
||
|
<TR>
|
||
|
<TD>
|
||
|
<B>Desired Result:</B>
|
||
|
</TD>
|
||
|
<TD>
|
||
|
<FONT COLOR="blue">1974</FONT>
|
||
|
<BR>
|
||
|
</TD>
|
||
|
</TR>
|
||
|
<TR>
|
||
|
<TD>
|
||
|
<B>Result:</B>
|
||
|
</TD>
|
||
|
<TD>
|
||
|
<FONT COLOR="blue">1974</FONT>
|
||
|
</TD>
|
||
|
</TR>
|
||
|
<TR>
|
||
|
<TD VALIGN="TOP">
|
||
|
<B>Test:</B>
|
||
|
</TD>
|
||
|
<TD><xsl:value-of select="(4+5)-(9+9)"/><BR>
|
||
|
</TD>
|
||
|
</TR>
|
||
|
<TR>
|
||
|
<TD>
|
||
|
<B>Desired Result:</B>
|
||
|
</TD>
|
||
|
<TD>
|
||
|
<FONT COLOR="blue">-9</FONT>
|
||
|
<BR>
|
||
|
</TD>
|
||
|
</TR>
|
||
|
<TR>
|
||
|
<TD>
|
||
|
<B>Result:</B>
|
||
|
</TD>
|
||
|
<TD>
|
||
|
<FONT COLOR="blue">-9</FONT>
|
||
|
</TD>
|
||
|
</TR>
|
||
|
</TABLE>
|
||
|
<HR>
|
||
|
<TABLE>
|
||
|
<TR BGColor="#E0E0FF">
|
||
|
<TD Colspan="2" ALIGN="CENTER">
|
||
|
<B>Multiplicative Expressions</B>
|
||
|
</TD>
|
||
|
</TR>
|
||
|
<TR>
|
||
|
<TD VALIGN="TOP">
|
||
|
<B>Test:</B>
|
||
|
</TD>
|
||
|
<TD><xsl:value-of select="7*4"/><BR>
|
||
|
</TD>
|
||
|
</TR>
|
||
|
<TR>
|
||
|
<TD>
|
||
|
<B>Desired Result:</B>
|
||
|
</TD>
|
||
|
<TD>
|
||
|
<FONT COLOR="blue">28</FONT>
|
||
|
<BR>
|
||
|
</TD>
|
||
|
</TR>
|
||
|
<TR>
|
||
|
<TD>
|
||
|
<B>Result:</B>
|
||
|
</TD>
|
||
|
<TD>
|
||
|
<FONT COLOR="blue">28</FONT>
|
||
|
</TD>
|
||
|
</TR>
|
||
|
<TR>
|
||
|
<TD VALIGN="TOP">
|
||
|
<B>Test:</B>
|
||
|
</TD>
|
||
|
<TD><xsl:value-of select="7mod4"/><BR>
|
||
|
</TD>
|
||
|
</TR>
|
||
|
<TR>
|
||
|
<TD>
|
||
|
<B>Desired Result:</B>
|
||
|
</TD>
|
||
|
<TD>
|
||
|
<FONT COLOR="blue">3</FONT>
|
||
|
<BR>
|
||
|
</TD>
|
||
|
</TR>
|
||
|
<TR>
|
||
|
<TD>
|
||
|
<B>Result:</B>
|
||
|
</TD>
|
||
|
<TD>
|
||
|
<FONT COLOR="blue">3</FONT>
|
||
|
</TD>
|
||
|
</TR>
|
||
|
<TR>
|
||
|
<TD VALIGN="TOP">
|
||
|
<B>Test:</B>
|
||
|
</TD>
|
||
|
<TD><xsl:value-of select="7div4"/><BR>
|
||
|
</TD>
|
||
|
</TR>
|
||
|
<TR>
|
||
|
<TD>
|
||
|
<B>Desired Result:</B>
|
||
|
</TD>
|
||
|
<TD>
|
||
|
<FONT COLOR="blue">1.75</FONT>
|
||
|
<BR>
|
||
|
</TD>
|
||
|
</TR>
|
||
|
<TR>
|
||
|
<TD>
|
||
|
<B>Result:</B>
|
||
|
</TD>
|
||
|
<TD>
|
||
|
<FONT COLOR="blue">1.75</FONT>
|
||
|
</TD>
|
||
|
</TR>
|
||
|
<TR>
|
||
|
<TD VALIGN="TOP">
|
||
|
<B>Test:</B>
|
||
|
</TD>
|
||
|
<TD><xsl:value-of select="7div0"/><BR>
|
||
|
</TD>
|
||
|
</TR>
|
||
|
<TR>
|
||
|
<TD>
|
||
|
<B>Desired Result:</B>
|
||
|
</TD>
|
||
|
<TD>
|
||
|
<FONT COLOR="blue">Infinity</FONT>
|
||
|
<BR>
|
||
|
</TD>
|
||
|
</TR>
|
||
|
<TR>
|
||
|
<TD>
|
||
|
<B>Result:</B>
|
||
|
</TD>
|
||
|
<TD>
|
||
|
<FONT COLOR="blue">Infinity</FONT>
|
||
|
</TD>
|
||
|
</TR>
|
||
|
<TR>
|
||
|
<TD VALIGN="TOP">
|
||
|
<B>Test:</B>
|
||
|
</TD>
|
||
|
<TD><xsl:value-of select="0 div 0"/><BR>
|
||
|
</TD>
|
||
|
</TR>
|
||
|
<TR>
|
||
|
<TD>
|
||
|
<B>Desired Result:</B>
|
||
|
</TD>
|
||
|
<TD>
|
||
|
<FONT COLOR="blue">NaN</FONT>
|
||
|
<BR>
|
||
|
</TD>
|
||
|
</TR>
|
||
|
<TR>
|
||
|
<TD>
|
||
|
<B>Result:</B>
|
||
|
</TD>
|
||
|
<TD>
|
||
|
<FONT COLOR="blue">NaN</FONT>
|
||
|
</TD>
|
||
|
</TR>
|
||
|
<TR>
|
||
|
<TD VALIGN="TOP">
|
||
|
<B>Test:</B>
|
||
|
</TD>
|
||
|
<TD><xsl:variable name="x" select="7*3"/><BR><xsl:variable name="y" select="3"/><BR><xsl:value-of select="$x div $y"/><BR>
|
||
|
</TD>
|
||
|
</TR>
|
||
|
<TR>
|
||
|
<TD>
|
||
|
<B>Desired Result:</B>
|
||
|
</TD>
|
||
|
<TD>
|
||
|
<FONT COLOR="blue">7</FONT>
|
||
|
<BR>
|
||
|
</TD>
|
||
|
</TR>
|
||
|
<TR>
|
||
|
<TD>
|
||
|
<B>Result:</B>
|
||
|
</TD>
|
||
|
<TD>
|
||
|
<FONT COLOR="blue">7<BR>
|
||
|
</FONT>
|
||
|
</TD>
|
||
|
</TR>
|
||
|
</TABLE>
|
||
|
<TABLE>
|
||
|
<TR BGColor="#E0E0FF">
|
||
|
<TD Colspan="2" ALIGN="CENTER">
|
||
|
<B>Precedence tests</B>
|
||
|
</TD>
|
||
|
</TR>
|
||
|
<TR>
|
||
|
<TD VALIGN="TOP">
|
||
|
<B>Test:</B>
|
||
|
</TD>
|
||
|
<TD><xsl:value-of select="2 mod 2 = 0"/><BR>
|
||
|
</TD>
|
||
|
</TR>
|
||
|
<TR>
|
||
|
<TD>
|
||
|
<B>Desired Result:</B>
|
||
|
</TD>
|
||
|
<TD>
|
||
|
<FONT COLOR="blue">true</FONT>
|
||
|
<BR>
|
||
|
</TD>
|
||
|
</TR>
|
||
|
<TR>
|
||
|
<TD>
|
||
|
<B>Result:</B>
|
||
|
</TD>
|
||
|
<TD>
|
||
|
<FONT COLOR="blue">true</FONT>
|
||
|
</TD>
|
||
|
</TR>
|
||
|
<TR>
|
||
|
<TD VALIGN="TOP">
|
||
|
<B>Test:</B>
|
||
|
</TD>
|
||
|
<TD><xsl:value-of select="5 mod 2<5 and 2*6>= 12"/><BR>
|
||
|
</TD>
|
||
|
</TR>
|
||
|
<TR>
|
||
|
<TD>
|
||
|
<B>Desired Result:</B>
|
||
|
</TD>
|
||
|
<TD>
|
||
|
<FONT COLOR="blue">true</FONT>
|
||
|
<BR>
|
||
|
</TD>
|
||
|
</TR>
|
||
|
<TR>
|
||
|
<TD>
|
||
|
<B>Result:</B>
|
||
|
</TD>
|
||
|
<TD>
|
||
|
<FONT COLOR="blue">true</FONT>
|
||
|
</TD>
|
||
|
</TR>
|
||
|
<TR>
|
||
|
<TD VALIGN="TOP">
|
||
|
<B>Test:</B>
|
||
|
</TD>
|
||
|
<TD><xsl:value-of select="5 mod 2<5 and 2*6>12"/><BR>
|
||
|
</TD>
|
||
|
</TR>
|
||
|
<TR>
|
||
|
<TD>
|
||
|
<B>Desired Result:</B>
|
||
|
</TD>
|
||
|
<TD>
|
||
|
<FONT COLOR="blue">false</FONT>
|
||
|
<BR>
|
||
|
</TD>
|
||
|
</TR>
|
||
|
<TR>
|
||
|
<TD>
|
||
|
<B>Result:</B>
|
||
|
</TD>
|
||
|
<TD>
|
||
|
<FONT COLOR="blue">false</FONT>
|
||
|
</TD>
|
||
|
</TR>
|
||
|
<TR>
|
||
|
<TD VALIGN="TOP">
|
||
|
<B>Test:</B>
|
||
|
</TD>
|
||
|
<TD><xsl:value-of select="4+5*3"/><BR>
|
||
|
</TD>
|
||
|
</TR>
|
||
|
<TR>
|
||
|
<TD>
|
||
|
<B>Desired Result:</B>
|
||
|
</TD>
|
||
|
<TD>
|
||
|
<FONT COLOR="blue">19</FONT>
|
||
|
<BR>
|
||
|
</TD>
|
||
|
</TR>
|
||
|
<TR>
|
||
|
<TD>
|
||
|
<B>Result:</B>
|
||
|
</TD>
|
||
|
<TD>
|
||
|
<FONT COLOR="blue">19</FONT>
|
||
|
</TD>
|
||
|
</TR>
|
||
|
<TR>
|
||
|
<TD VALIGN="TOP">
|
||
|
<B>Test:</B>
|
||
|
</TD>
|
||
|
<TD><xsl:value-of select="4+5*3+(6-4)*7"/><BR>
|
||
|
</TD>
|
||
|
</TR>
|
||
|
<TR>
|
||
|
<TD>
|
||
|
<B>Desired Result:</B>
|
||
|
</TD>
|
||
|
<TD>
|
||
|
<FONT COLOR="blue">33</FONT>
|
||
|
<BR>
|
||
|
</TD>
|
||
|
</TR>
|
||
|
<TR>
|
||
|
<TD>
|
||
|
<B>Result:</B>
|
||
|
</TD>
|
||
|
<TD>
|
||
|
<FONT COLOR="blue">33</FONT>
|
||
|
</TD>
|
||
|
</TR>
|
||
|
</TABLE>
|
||
|
<TABLE>
|
||
|
<TR BGColor="#E0E0FF">
|
||
|
<TD Colspan="2" ALIGN="CENTER">
|
||
|
<B>Automatic Result Type Conversion</B>
|
||
|
</TD>
|
||
|
</TR>
|
||
|
<TR>
|
||
|
<TD VALIGN="TOP">
|
||
|
<B>Test:</B>
|
||
|
</TD>
|
||
|
<TD><xsl:value-of select="'747' + 8"/><BR>
|
||
|
</TD>
|
||
|
</TR>
|
||
|
<TR>
|
||
|
<TD>
|
||
|
<B>Desired Result:</B>
|
||
|
</TD>
|
||
|
<TD>
|
||
|
<FONT COLOR="blue">755</FONT>
|
||
|
<BR>
|
||
|
</TD>
|
||
|
</TR>
|
||
|
<TR>
|
||
|
<TD>
|
||
|
<B>Result:</B>
|
||
|
</TD>
|
||
|
<TD>
|
||
|
<FONT COLOR="blue">755</FONT>
|
||
|
</TD>
|
||
|
</TR>
|
||
|
</TABLE>
|
||
|
</BODY>
|
||
|
</HTML>
|