I want to get ideas for customizing my Ranorex report. Can anyone share some examples of ways you have customized your report to provide more value or organized the information better?
One thing I might like to do is expand the test data portion of my cases automatically while leaving the other sections collapsed.
Custom Report Examples
Re: Custom Report Examples
Hi,
The only customization I'm doing in my reports is adding data connector rows in the header of each iteration. So then I can easily identify individual iterations, without the need to expand each iteration. I'm adding this code to RanorexReport.xsl (right after "<!--PARAMETER OR DATA COLUMN 'NAME - VALUE' TEMPLATE-->" section):
The only customization I'm doing in my reports is adding data connector rows in the header of each iteration. So then I can easily identify individual iterations, without the need to expand each iteration. I'm adding this code to RanorexReport.xsl (right after "<!--PARAMETER OR DATA COLUMN 'NAME - VALUE' TEMPLATE-->" section):
Code: Select all
<xsl:template match="activity[(@type='test-case' or @type='smart-folder') and @type!='iteration-container' and @activity-exectype='dataiteration']">
<xsl:param name="itemCount" />
<li class="{@result} iteration" id="iteration{@rid}">
<h2 class="{@result}" onclick="OnLoadContentDynamic('{@rid}','iteration',this);">
<span class="ui-status-icon"></span>
<xsl:choose>
<xsl:when test="@type='test-case' or (@type='smart-folder' and @type!='iteration-container' and @activity-exectype='dataiteration')">Iteration: </xsl:when>
<xsl:otherwise>Repeat: </xsl:otherwise>
</xsl:choose>
<xsl:value-of select="./@iteration" />
<xsl:value-of select="./datarow/field" />
<xsl:if test=".//item[@level='Warn']">
<span class="ui-module-icon warn"></span>
</xsl:if>
<xsl:if test=".//item[@level='Error']">
<span class="ui-module-icon error"></span>
</xsl:if>
<span class="duration">
<xsl:value-of select="./@duration" />
</span>
</h2>
<ul>
<xsl:if test="./datarow/field">
<div class="datarow">
<xsl:apply-templates select="./datarow" />
</div>
</xsl:if>
<xsl:if test="$loadAll = 1">
<xsl:apply-templates select="./activity">
<xsl:with-param name="itemCount" select="$itemCount" />
</xsl:apply-templates>
</xsl:if>
</ul>
</li>
</xsl:template>
You do not have the required permissions to view the files attached to this post.
Pavel Kudrys
Ranorex explorer at Descartes Systems
Please add these details to your questions:
Ranorex explorer at Descartes Systems
Please add these details to your questions:
- Ranorex Snapshot. Learn how to create one >here<
- Ranorex xPath of problematic element(s)
- Ranorex version
- OS version
- HW configuration
-
- Posts: 52
- Joined: Fri Mar 21, 2014 4:22 pm
Re: Custom Report Examples
@odklizec Thank you so much for posting this. Many moons ago I had given up on finding a way to include data items in the Iteration headers, today I had a quick search and found your post. Even though I don't really understand XSL a bit of trial and error got me to the result I wanted. Iteration: N [data item 1] [data item 2]
Re: Custom Report Examples
Hi, you are welcome. I'm glad my example helped you
Pavel Kudrys
Ranorex explorer at Descartes Systems
Please add these details to your questions:
Ranorex explorer at Descartes Systems
Please add these details to your questions:
- Ranorex Snapshot. Learn how to create one >here<
- Ranorex xPath of problematic element(s)
- Ranorex version
- OS version
- HW configuration