You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@maven.apache.org by mi...@apache.org on 2023/05/29 19:35:12 UTC
[maven-surefire] branch master updated: [SUREFIRE-1533] surefire-test-report.xsd has too narrow a definition for testcase time attribute
This is an automated email from the ASF dual-hosted git repository.
michaelo pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/maven-surefire.git
The following commit(s) were added to refs/heads/master by this push:
new 2a0e80de9 [SUREFIRE-1533] surefire-test-report.xsd has too narrow a definition for testcase time attribute
2a0e80de9 is described below
commit 2a0e80de9af441e35b8fc226769574e2077251a9
Author: Michael Osipov <mi...@apache.org>
AuthorDate: Mon May 29 21:34:37 2023 +0200
[SUREFIRE-1533] surefire-test-report.xsd has too narrow a definition for testcase time attribute
---
.../maven/plugins/surefire/report/TestSuiteXmlParserTest.java | 6 +++---
1 file changed, 3 insertions(+), 3 deletions(-)
diff --git a/surefire-report-parser/src/test/java/org/apache/maven/plugins/surefire/report/TestSuiteXmlParserTest.java b/surefire-report-parser/src/test/java/org/apache/maven/plugins/surefire/report/TestSuiteXmlParserTest.java
index 1725e2d64..a76b6356a 100644
--- a/surefire-report-parser/src/test/java/org/apache/maven/plugins/surefire/report/TestSuiteXmlParserTest.java
+++ b/surefire-report-parser/src/test/java/org/apache/maven/plugins/surefire/report/TestSuiteXmlParserTest.java
@@ -113,12 +113,12 @@ public class TestSuiteXmlParserTest {
public void testParse() throws Exception {
TestSuiteXmlParser testSuiteXmlParser = new TestSuiteXmlParser(consoleLogger);
String xml = "<?xml version=\"1.0\" encoding=\"UTF-8\" ?>\n"
- + "<testsuite failures=\"4\" time=\"0.005\" errors=\"0\" skipped=\"0\" tests=\"4\" name=\"wellFormedXmlFailures.TestSurefire3\">\n"
+ + "<testsuite failures=\"4\" time=\"0.00005\" errors=\"0\" skipped=\"0\" tests=\"4\" name=\"wellFormedXmlFailures.TestSurefire3\">\n"
+ " <properties>\n"
+ " <property name=\"java.runtime.name\" value=\"Java(TM) SE Runtime Environment\"/>\n"
+ " <property name=\"sun.cpu.isalist\" value=\"amd64\"/>\n"
+ " </properties>\n"
- + " <testcase time=\"0.005\" classname=\"wellFormedXmlFailures.TestSurefire3\" name=\"testLower\">\n"
+ + " <testcase time=\"5E-3\" classname=\"wellFormedXmlFailures.TestSurefire3\" name=\"testLower\">\n"
+ " <failure message=\"<\" type=\"junit.framework.AssertionFailedError\"><![CDATA[junit.framework.AssertionFailedError: <\n"
+ "\tat junit.framework.Assert.fail(Assert.java:47)\n"
+ "\tat wellFormedXmlFailures.TestSurefire3.testLower(TestSurefire3.java:30)\n"
@@ -155,7 +155,7 @@ public class TestSuiteXmlParserTest {
assertThat(report.getNumberOfErrors(), is(0));
assertThat(report.getNumberOfFailures(), is(4));
assertThat(report.getNumberOfFlakes(), is(0));
- assertThat(report.getTimeElapsed(), is(0.005f));
+ assertThat(report.getTimeElapsed(), is(0.00005f));
assertThat(report.getTestCases().size(), is(4));
List<ReportTestCase> tests = report.getTestCases();