My favorites | Sign in
Project Home Downloads Source
READ-ONLY: This project has been archived. For more information see this post.
Search
for
  Advanced search   Search tips   Subscriptions
Issue 143: PATCH: links on HTML reports
1 person starred this issue and may be notified of changes. Back to list
Status:  Fixed
Owner:  ----
Closed:  Dec 2008
Cc:  marc.es...@gmail.com


 
Reported by bboisv...@gmail.com, Dec 12, 2008
Here's a simple patch to XMLTestResult that turns the test case and test
method strings into links to the appropriate runs.  I'm not sure if it'll
handle all cases (since I know virtually nothing about the guts of MXUnit),
but it works for me.

Index: C:/apps/wwwroot/eventlog/lib/mxunit/framework/XMLTestResult.cfc
===================================================================
--- C:/apps/wwwroot/eventlog/lib/mxunit/framework/XMLTestResult.cfc
(revision 481)
+++ C:/apps/wwwroot/eventlog/lib/mxunit/framework/XMLTestResult.cfc
(working copy)
@@ -290,11 +290,13 @@
    <xsl:otherwise>white</xsl:otherwise>
   </xsl:choose>
  </xsl:variable>
+<xsl:variable name="linkroot">#getContextRoot()#/<xsl:value-of
select="translate(@component, ''.'', ''/'')"
/>.cfc?method=runtestremote&amp;output=html</xsl:variable>
  <tr bgcolor="{$bgcolor}" valign="top">
   <xsl:variable name="rowid" select="@number" />
   <td><xsl:value-of select="@number" />.</td>
   <td><xsl:value-of select="date" /></td>
-  <td align="left" nowrap="true"><xsl:value-of select="@component"
/>.<xsl:value-of select="@testname" />()</td>
+  <td align="left" nowrap="true">
+<a href="{$linkroot}"><xsl:value-of select="@component" /></a>.<a
href="{$linkroot}&amp;testmethod={@testname}"><xsl:value-of
select="@testname" /></a>()</td>
   <td>
   <xsl:variable name="failed" select="results/message" />
   <xsl:choose>

Dec 13, 2008
Project Member #1 virtix
Thanks, Barney! Good stuff. This and #144 also committed. I only added title="..."
for call outs.
Status: Fixed
Cc: marc.esher
Labels: Type-Enhancement

Powered by Google Project Hosting