mirror of
https://github.com/dorny/test-reporter.git
synced 2026-02-04 21:47:56 +01:00
Merge eedd088b6d into 20823bb69a
This commit is contained in:
commit
29a2f22c83
11 changed files with 1255 additions and 0 deletions
4
__tests__/fixtures/open-test-reporting/empty.xml
Normal file
4
__tests__/fixtures/open-test-reporting/empty.xml
Normal file
|
|
@ -0,0 +1,4 @@
|
|||
<?xml version="1.0" encoding="UTF-8" standalone="no"?>
|
||||
<h:execution xmlns:h="https://schemas.opentest4j.org/reporting/hierarchy/0.2.0"
|
||||
xmlns="https://schemas.opentest4j.org/reporting/core/0.2.0">
|
||||
</h:execution>
|
||||
71
__tests__/fixtures/open-test-reporting/events.xml
Normal file
71
__tests__/fixtures/open-test-reporting/events.xml
Normal file
|
|
@ -0,0 +1,71 @@
|
|||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<e:events xmlns="https://schemas.opentest4j.org/reporting/core/0.2.0"
|
||||
xmlns:e="https://schemas.opentest4j.org/reporting/events/0.2.0">
|
||||
<infrastructure>
|
||||
<hostName>build-agent-02</hostName>
|
||||
<userName>runner</userName>
|
||||
<operatingSystem>macOS</operatingSystem>
|
||||
<cpuCores>8</cpuCores>
|
||||
</infrastructure>
|
||||
|
||||
<!-- Suite: CalculatorTest starts -->
|
||||
<e:started id="suite-1" name="com.example.CalculatorTest" time="2024-01-15T11:00:00.000Z"/>
|
||||
|
||||
<!-- Test: testAddition -->
|
||||
<e:started id="test-1" name="testAddition" parentId="suite-1" time="2024-01-15T11:00:00.100Z"/>
|
||||
<e:finished id="test-1" time="2024-01-15T11:00:00.200Z">
|
||||
<result status="SUCCESSFUL"/>
|
||||
</e:finished>
|
||||
|
||||
<!-- Test: testSubtraction -->
|
||||
<e:started id="test-2" name="testSubtraction" parentId="suite-1" time="2024-01-15T11:00:00.250Z"/>
|
||||
<e:finished id="test-2" time="2024-01-15T11:00:00.400Z">
|
||||
<result status="SUCCESSFUL"/>
|
||||
</e:finished>
|
||||
|
||||
<!-- Test: testDivision (fails) -->
|
||||
<e:started id="test-3" name="testDivision" parentId="suite-1" time="2024-01-15T11:00:00.450Z"/>
|
||||
<e:finished id="test-3" time="2024-01-15T11:00:00.600Z">
|
||||
<result status="FAILED">
|
||||
<reason>java.lang.ArithmeticException: Division by zero</reason>
|
||||
</result>
|
||||
</e:finished>
|
||||
|
||||
<!-- Test: testMultiplication (skipped) -->
|
||||
<e:started id="test-4" name="testMultiplication" parentId="suite-1" time="2024-01-15T11:00:00.650Z"/>
|
||||
<e:finished id="test-4" time="2024-01-15T11:00:00.660Z">
|
||||
<result status="SKIPPED">
|
||||
<reason>Test disabled</reason>
|
||||
</result>
|
||||
</e:finished>
|
||||
|
||||
<!-- Suite: CalculatorTest finishes -->
|
||||
<e:finished id="suite-1" time="2024-01-15T11:00:00.700Z">
|
||||
<result status="FAILED"/>
|
||||
</e:finished>
|
||||
|
||||
<!-- Suite: StringUtilsTest starts -->
|
||||
<e:started id="suite-2" name="com.example.StringUtilsTest" time="2024-01-15T11:00:01.000Z"/>
|
||||
|
||||
<!-- Group: TrimTests -->
|
||||
<e:started id="group-1" name="TrimTests" parentId="suite-2" time="2024-01-15T11:00:01.100Z"/>
|
||||
|
||||
<e:started id="test-5" name="testTrimLeft" parentId="group-1" time="2024-01-15T11:00:01.110Z"/>
|
||||
<e:finished id="test-5" time="2024-01-15T11:00:01.200Z">
|
||||
<result status="SUCCESSFUL"/>
|
||||
</e:finished>
|
||||
|
||||
<e:started id="test-6" name="testTrimRight" parentId="group-1" time="2024-01-15T11:00:01.210Z"/>
|
||||
<e:finished id="test-6" time="2024-01-15T11:00:01.300Z">
|
||||
<result status="SUCCESSFUL"/>
|
||||
</e:finished>
|
||||
|
||||
<e:finished id="group-1" time="2024-01-15T11:00:01.310Z">
|
||||
<result status="SUCCESSFUL"/>
|
||||
</e:finished>
|
||||
|
||||
<!-- Suite: StringUtilsTest finishes -->
|
||||
<e:finished id="suite-2" time="2024-01-15T11:00:01.400Z">
|
||||
<result status="SUCCESSFUL"/>
|
||||
</e:finished>
|
||||
</e:events>
|
||||
60
__tests__/fixtures/open-test-reporting/hierarchy.xml
Normal file
60
__tests__/fixtures/open-test-reporting/hierarchy.xml
Normal file
|
|
@ -0,0 +1,60 @@
|
|||
<?xml version="1.0" encoding="UTF-8" standalone="no"?>
|
||||
<h:execution xmlns:h="https://schemas.opentest4j.org/reporting/hierarchy/0.2.0"
|
||||
xmlns="https://schemas.opentest4j.org/reporting/core/0.2.0">
|
||||
<infrastructure>
|
||||
<hostName>build-agent-01</hostName>
|
||||
<userName>ci</userName>
|
||||
<operatingSystem>Linux</operatingSystem>
|
||||
<cpuCores>4</cpuCores>
|
||||
</infrastructure>
|
||||
|
||||
<!-- Suite: UserServiceTest -->
|
||||
<h:root duration="PT1.234S" name="com.example.UserServiceTest" start="2024-01-15T10:30:00.000Z">
|
||||
<result status="SUCCESSFUL"/>
|
||||
<h:child duration="PT0.123S" name="testUserCreation" start="2024-01-15T10:30:00.100Z">
|
||||
<result status="SUCCESSFUL"/>
|
||||
</h:child>
|
||||
<h:child duration="PT0.234S" name="testUserDeletion" start="2024-01-15T10:30:00.300Z">
|
||||
<result status="SUCCESSFUL"/>
|
||||
</h:child>
|
||||
<h:child duration="PT0.045S" name="testUserUpdate" start="2024-01-15T10:30:00.600Z">
|
||||
<result status="SKIPPED">
|
||||
<reason>Skipped: Database not available</reason>
|
||||
</result>
|
||||
</h:child>
|
||||
</h:root>
|
||||
|
||||
<!-- Suite: PaymentServiceTest with nested groups -->
|
||||
<h:root duration="PT2.5S" name="com.example.PaymentServiceTest" start="2024-01-15T10:30:02.000Z">
|
||||
<result status="FAILED"/>
|
||||
|
||||
<!-- Group: ValidationTests -->
|
||||
<h:child duration="PT0.8S" name="ValidationTests" start="2024-01-15T10:30:02.100Z">
|
||||
<result status="SUCCESSFUL"/>
|
||||
<h:child duration="PT0.2S" name="testValidAmount" start="2024-01-15T10:30:02.110Z">
|
||||
<result status="SUCCESSFUL"/>
|
||||
</h:child>
|
||||
<h:child duration="PT0.3S" name="testInvalidAmount" start="2024-01-15T10:30:02.320Z">
|
||||
<result status="SUCCESSFUL"/>
|
||||
</h:child>
|
||||
</h:child>
|
||||
|
||||
<!-- Group: ProcessingTests -->
|
||||
<h:child duration="PT1.2S" name="ProcessingTests" start="2024-01-15T10:30:03.000Z">
|
||||
<result status="FAILED"/>
|
||||
<h:child duration="PT0.5S" name="testSuccessfulPayment" start="2024-01-15T10:30:03.100Z">
|
||||
<result status="SUCCESSFUL"/>
|
||||
</h:child>
|
||||
<h:child duration="PT0.7S" name="testPaymentTimeout" start="2024-01-15T10:30:03.700Z">
|
||||
<result status="FAILED">
|
||||
<reason>org.opentest4j.AssertionFailedError: Payment should complete within 500ms but took 700ms</reason>
|
||||
</result>
|
||||
</h:child>
|
||||
</h:child>
|
||||
</h:root>
|
||||
|
||||
<!-- Suite: EmptySuite (edge case) -->
|
||||
<h:root duration="PT0S" name="com.example.EmptySuite" start="2024-01-15T10:30:05.000Z">
|
||||
<result status="SUCCESSFUL"/>
|
||||
</h:root>
|
||||
</h:execution>
|
||||
Loading…
Add table
Add a link
Reference in a new issue