curcuru     02/01/30 12:16:24

  Modified:    test     ResultScanner.xsl
  Log:
  Add inefficient but very useful miniStatusTable at top of output
  
  Revision  Changes    Path
  1.3       +32 -1     xml-xalan/test/ResultScanner.xsl
  
  Index: ResultScanner.xsl
  ===================================================================
  RCS file: /home/cvs/xml-xalan/test/ResultScanner.xsl,v
  retrieving revision 1.2
  retrieving revision 1.3
  diff -u -r1.2 -r1.3
  --- ResultScanner.xsl 24 Jan 2002 17:22:54 -0000      1.2
  +++ ResultScanner.xsl 30 Jan 2002 20:16:24 -0000      1.3
  @@ -33,6 +33,7 @@
               <xsl:attribute name="href">#<xsl:value-of 
select="$linkname"/></xsl:attribute>
               <xsl:value-of select="$linkname"/>
             </xsl:element>
  +          <xsl:call-template name="miniStatusTable" />
             <br/>
         </xsl:for-each>
         <xsl:apply-templates/>
  @@ -40,6 +41,32 @@
     </html>
   </xsl:template>
   
  +<!-- For each bad file, pre-read summary -->
  +<xsl:template name="miniStatusTable">
  +  <!-- Note this entire template is quite inefficient, since it 
  +        forces an extra loading of the status doc that will be 
  +        loaded again later on, but it works for now.
  +  -->
  +  <!-- Read in the teststatus file we found and get it's info -->
  +  <xsl:variable name="statusfilename" select="concat(../@href, '/', @href)"/>
  +  <xsl:variable name="status" select="document($statusfilename)/teststatus"/>
  +  <xsl:text> P: </xsl:text>
  +  <xsl:value-of select="$status/@Pass-cases"/><xsl:text>/</xsl:text>
  +  <xsl:value-of select="$status/@Pass-checks"/><xsl:text>, </xsl:text>
  +  <xsl:text>F: </xsl:text>
  +  <xsl:value-of select="$status/@Fail-cases"/><xsl:text>/</xsl:text>
  +  <xsl:value-of select="$status/@Fail-checks"/><xsl:text>, </xsl:text>
  +  <xsl:text>E: </xsl:text>
  +  <xsl:value-of select="$status/@Errr-cases"/><xsl:text>/</xsl:text>
  +  <xsl:value-of select="$status/@Errr-checks"/><xsl:text>, </xsl:text>
  +  <xsl:text>A: </xsl:text>
  +  <xsl:value-of select="$status/@Ambg-cases"/><xsl:text>/</xsl:text>
  +  <xsl:value-of select="$status/@Ambg-checks"/><xsl:text>, </xsl:text>
  +  <xsl:text>I: </xsl:text>
  +  <xsl:value-of select="$status/@Incp-cases"/>
  +
  +</xsl:template>
  +
   <!-- For each directory full of results found, print out a summary -->
   <xsl:template match="testgroup">
     <!-- Cache the value of the dir for later use -->
  @@ -54,7 +81,11 @@
     </xsl:apply-templates>
   </xsl:template>
   
  -<!-- Just list names of good result files (passing), nothing else -->
  +<!-- Just list names of good result files (passing/ambg), nothing else -->
  +<xsl:template match="[EMAIL PROTECTED] = $goodResult][starts-with(@href, 
'Ambg')]">
  +  <b><xsl:value-of select="@href"/></b><xsl:text> </xsl:text>
  +</xsl:template>
  +
   <xsl:template match="[EMAIL PROTECTED] = $goodResult]">
     <xsl:value-of select="@href"/><xsl:text> </xsl:text>
   </xsl:template>
  
  
  

---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to