aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--ChangeLog7
-rw-r--r--tests/junit-runner/JunitLikeXmlOutputListener.java4
-rw-r--r--tests/report-styles/jreport.xsl12
3 files changed, 22 insertions, 1 deletions
diff --git a/ChangeLog b/ChangeLog
index f2114e1..5b4a9bc 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,10 @@
+2012-06-13 Jiri Vanek <[email protected]>
+
+ * tests/junit-runner/JunitLikeXmlOutputListener.java:
+ Introduced TEST_IGNORED_ATTRIBUTE to mark test as ignored if should be.
+ * tests/report-styles/jreport.xsl: Applied correct text and style for
+ tests with attribute ignored.
+
2012-06-12 Adam Domurad <[email protected]>
Fixes PR722, javaws failing to run with unsigned content in META-INF/
diff --git a/tests/junit-runner/JunitLikeXmlOutputListener.java b/tests/junit-runner/JunitLikeXmlOutputListener.java
index 7febaa1..fe17f19 100644
--- a/tests/junit-runner/JunitLikeXmlOutputListener.java
+++ b/tests/junit-runner/JunitLikeXmlOutputListener.java
@@ -51,6 +51,7 @@ public class JunitLikeXmlOutputListener extends RunListener {
private static final String K2F = "known-to-fail";
private static final String TEST_NAME_ATTRIBUTE = "name";
private static final String TEST_TIME_ATTRIBUTE = "time";
+ private static final String TEST_IGNORED_ATTRIBUTE = "ignored";
private static final String TEST_ERROR_ELEMENT = "error";
private static final String TEST_CLASS_ATTRIBUTE = "classname";
private static final String ERROR_MESSAGE_ATTRIBUTE = "message";
@@ -193,6 +194,9 @@ public class JunitLikeXmlOutputListener extends RunListener {
testcaseAtts.put(TEST_TIME_ATTRIBUTE, stringedTime);
testcaseAtts.put(TEST_CLASS_ATTRIBUTE, description.getClassName());
testcaseAtts.put(TEST_NAME_ATTRIBUTE, description.getMethodName());
+ if (ignored){
+ testcaseAtts.put(TEST_IGNORED_ATTRIBUTE, Boolean.TRUE.toString());
+ }
KnownToFail k2f=null;
try {
if (testClass != null && testMethod != null) {
diff --git a/tests/report-styles/jreport.xsl b/tests/report-styles/jreport.xsl
index a54d0f9..cf9c58a 100644
--- a/tests/report-styles/jreport.xsl
+++ b/tests/report-styles/jreport.xsl
@@ -201,6 +201,9 @@ If there is no need for linking, please use value "none" for this variable
<div>
<xsl:attribute name="class">
<xsl:choose>
+ <xsl:when test="@ignored">
+ ignored
+ </xsl:when>
<xsl:when test="error">
failed
</xsl:when>
@@ -246,7 +249,14 @@ If there is no need for linking, please use value "none" for this variable
<xsl:choose>
<xsl:when test="not(error)">
<div class="status">
- PASSED (<xsl:value-of select="@time"/>s)
+ <xsl:choose>
+ <xsl:when test="@ignored">
+ IGNORED (<xsl:value-of select="@time"/>s)
+ </xsl:when>
+ <xsl:otherwise>
+ PASSED (<xsl:value-of select="@time"/>s)
+ </xsl:otherwise>
+ </xsl:choose>
<xsl:choose>
<xsl:when test="@known-to-fail">
<xsl:choose>