mirror of
https://github.com/dorny/test-reporter.git
synced 2025-12-18 07:07:08 +01:00
Merge 0dee8ba699 into c883ae9738
This commit is contained in:
commit
4dec797f6d
18 changed files with 37 additions and 18 deletions
|
|
@ -1,4 +1,5 @@
|
||||||

|
[](#user-content-test-report)
|
||||||
|
# <a name="user-content-test-report"></a> Tests report
|
||||||
|Report|Passed|Failed|Skipped|Time|
|
|Report|Passed|Failed|Skipped|Time|
|
||||||
|:---|---:|---:|---:|---:|
|
|:---|---:|---:|---:|---:|
|
||||||
|[fixtures/dart-json.json](#user-content-r0)|1 ✅|4 ❌|1 ⚪|4s|
|
|[fixtures/dart-json.json](#user-content-r0)|1 ✅|4 ❌|1 ⚪|4s|
|
||||||
|
|
|
||||||
|
|
@ -1,4 +1,5 @@
|
||||||

|
[](#user-content-test-report)
|
||||||
|
# <a name="user-content-test-report"></a> Tests report
|
||||||
|Report|Passed|Failed|Skipped|Time|
|
|Report|Passed|Failed|Skipped|Time|
|
||||||
|:---|---:|---:|---:|---:|
|
|:---|---:|---:|---:|---:|
|
||||||
|[fixtures/dotnet-nunit.xml](#user-content-r0)|3 ✅|5 ❌|1 ⚪|230ms|
|
|[fixtures/dotnet-nunit.xml](#user-content-r0)|3 ✅|5 ❌|1 ⚪|230ms|
|
||||||
|
|
|
||||||
|
|
@ -1,4 +1,5 @@
|
||||||

|
[](#user-content-test-report)
|
||||||
|
# <a name="user-content-test-report"></a> Tests report
|
||||||
|Report|Passed|Failed|Skipped|Time|
|
|Report|Passed|Failed|Skipped|Time|
|
||||||
|:---|---:|---:|---:|---:|
|
|:---|---:|---:|---:|---:|
|
||||||
|[fixtures/dotnet-trx.trx](#user-content-r0)|5 ✅|5 ❌|1 ⚪|1s|
|
|[fixtures/dotnet-trx.trx](#user-content-r0)|5 ✅|5 ❌|1 ⚪|1s|
|
||||||
|
|
|
||||||
|
|
@ -1,6 +1,7 @@
|
||||||

|
[](#user-content-test-report)
|
||||||
<details><summary>Expand for details</summary>
|
<details><summary>Expand for details</summary>
|
||||||
|
|
||||||
|
# <a name="user-content-test-report"></a> Tests report
|
||||||
|Report|Passed|Failed|Skipped|Time|
|
|Report|Passed|Failed|Skipped|Time|
|
||||||
|:---|---:|---:|---:|---:|
|
|:---|---:|---:|---:|---:|
|
||||||
|[fixtures/external/FluentValidation.Tests.trx](#user-content-r0)|803 ✅||1 ⚪|4s|
|
|[fixtures/external/FluentValidation.Tests.trx](#user-content-r0)|803 ✅||1 ⚪|4s|
|
||||||
|
|
|
||||||
|
|
@ -1,6 +1,7 @@
|
||||||

|
[](#user-content-test-report)
|
||||||
<details><summary>Expand for details</summary>
|
<details><summary>Expand for details</summary>
|
||||||
|
|
||||||
|
# <a name="user-content-test-report"></a> Tests report
|
||||||
|Report|Passed|Failed|Skipped|Time|
|
|Report|Passed|Failed|Skipped|Time|
|
||||||
|:---|---:|---:|---:|---:|
|
|:---|---:|---:|---:|---:|
|
||||||
|[fixtures/jest-junit-eslint.xml](#user-content-r0)|1 ✅|||0ms|
|
|[fixtures/jest-junit-eslint.xml](#user-content-r0)|1 ✅|||0ms|
|
||||||
|
|
|
||||||
|
|
@ -1,4 +1,5 @@
|
||||||

|
[](#user-content-test-report)
|
||||||
|
# <a name="user-content-test-report"></a> Tests report
|
||||||
|Report|Passed|Failed|Skipped|Time|
|
|Report|Passed|Failed|Skipped|Time|
|
||||||
|:---|---:|---:|---:|---:|
|
|:---|---:|---:|---:|---:|
|
||||||
|[fixtures/jest-junit.xml](#user-content-r0)|1 ✅|4 ❌|1 ⚪|1s|
|
|[fixtures/jest-junit.xml](#user-content-r0)|1 ✅|4 ❌|1 ⚪|1s|
|
||||||
|
|
|
||||||
|
|
@ -1,6 +1,7 @@
|
||||||

|
[](#user-content-test-report)
|
||||||
<details><summary>Expand for details</summary>
|
<details><summary>Expand for details</summary>
|
||||||
|
|
||||||
|
# <a name="user-content-test-report"></a> Tests report
|
||||||
|Report|Passed|Failed|Skipped|Time|
|
|Report|Passed|Failed|Skipped|Time|
|
||||||
|:---|---:|---:|---:|---:|
|
|:---|---:|---:|---:|---:|
|
||||||
|[fixtures/external/jest/jest-react-component-test-results.xml](#user-content-r0)|1 ✅|||1000ms|
|
|[fixtures/external/jest/jest-react-component-test-results.xml](#user-content-r0)|1 ✅|||1000ms|
|
||||||
|
|
|
||||||
|
|
@ -1,4 +1,5 @@
|
||||||

|
[](#user-content-test-report)
|
||||||
|
# <a name="user-content-test-report"></a> Tests report
|
||||||
|Report|Passed|Failed|Skipped|Time|
|
|Report|Passed|Failed|Skipped|Time|
|
||||||
|:---|---:|---:|---:|---:|
|
|:---|---:|---:|---:|---:|
|
||||||
|[fixtures/external/jest/jest-test-results.xml](#user-content-r0)|4207 ✅|2 ❌|30 ⚪|166s|
|
|[fixtures/external/jest/jest-test-results.xml](#user-content-r0)|4207 ✅|2 ❌|30 ⚪|166s|
|
||||||
|
|
|
||||||
|
|
@ -1,4 +1,5 @@
|
||||||

|
[](#user-content-test-report)
|
||||||
|
# <a name="user-content-test-report"></a> Tests report
|
||||||
|Report|Passed|Failed|Skipped|Time|
|
|Report|Passed|Failed|Skipped|Time|
|
||||||
|:---|---:|---:|---:|---:|
|
|:---|---:|---:|---:|---:|
|
||||||
|[fixtures/mocha-json.json](#user-content-r0)|1 ✅|4 ❌|1 ⚪|12ms|
|
|[fixtures/mocha-json.json](#user-content-r0)|1 ✅|4 ❌|1 ⚪|12ms|
|
||||||
|
|
|
||||||
|
|
@ -1,6 +1,7 @@
|
||||||

|
[](#user-content-test-report)
|
||||||
<details><summary>Expand for details</summary>
|
<details><summary>Expand for details</summary>
|
||||||
|
|
||||||
|
# <a name="user-content-test-report"></a> Tests report
|
||||||
|Report|Passed|Failed|Skipped|Time|
|
|Report|Passed|Failed|Skipped|Time|
|
||||||
|:---|---:|---:|---:|---:|
|
|:---|---:|---:|---:|---:|
|
||||||
|[fixtures/external/mocha/mocha-test-results.json](#user-content-r0)|833 ✅||6 ⚪|6s|
|
|[fixtures/external/mocha/mocha-test-results.json](#user-content-r0)|833 ✅||6 ⚪|6s|
|
||||||
|
|
|
||||||
|
|
@ -1,4 +1,5 @@
|
||||||

|
[](#user-content-test-report)
|
||||||
|
# <a name="user-content-test-report"></a> Tests report
|
||||||
|Report|Passed|Failed|Skipped|Time|
|
|Report|Passed|Failed|Skipped|Time|
|
||||||
|:---|---:|---:|---:|---:|
|
|:---|---:|---:|---:|---:|
|
||||||
|[fixtures/external/flutter/provider-test-results.json](#user-content-r0)|268 ✅|1 ❌||0ms|
|
|[fixtures/external/flutter/provider-test-results.json](#user-content-r0)|268 ✅|1 ❌||0ms|
|
||||||
|
|
|
||||||
|
|
@ -1,4 +1,5 @@
|
||||||

|
[](#user-content-test-report)
|
||||||
|
# <a name="user-content-test-report"></a> Tests report
|
||||||
|Report|Passed|Failed|Skipped|Time|
|
|Report|Passed|Failed|Skipped|Time|
|
||||||
|:---|---:|---:|---:|---:|
|
|:---|---:|---:|---:|---:|
|
||||||
|[fixtures/external/java/TEST-org.apache.pulsar.AddMissingPatchVersionTest.xml](#user-content-r0)||1 ❌|1 ⚪|116ms|
|
|[fixtures/external/java/TEST-org.apache.pulsar.AddMissingPatchVersionTest.xml](#user-content-r0)||1 ❌|1 ⚪|116ms|
|
||||||
|
|
|
||||||
|
|
@ -1,4 +1,5 @@
|
||||||

|
[](#user-content-test-report)
|
||||||
|
# <a name="user-content-test-report"></a> Tests report
|
||||||
|Report|Passed|Failed|Skipped|Time|
|
|Report|Passed|Failed|Skipped|Time|
|
||||||
|:---|---:|---:|---:|---:|
|
|:---|---:|---:|---:|---:|
|
||||||
|[fixtures/external/java/pulsar-test-report.xml](#user-content-r0)|793 ✅|1 ❌|14 ⚪|2127s|
|
|[fixtures/external/java/pulsar-test-report.xml](#user-content-r0)|793 ✅|1 ❌|14 ⚪|2127s|
|
||||||
|
|
|
||||||
|
|
@ -1,4 +1,5 @@
|
||||||

|
[](#user-content-test-report)
|
||||||
|
# <a name="user-content-test-report"></a> Tests report
|
||||||
|Report|Passed|Failed|Skipped|Time|
|
|Report|Passed|Failed|Skipped|Time|
|
||||||
|:---|---:|---:|---:|---:|
|
|:---|---:|---:|---:|---:|
|
||||||
|[fixtures/rspec-json.json](#user-content-r0)|1 ✅|1 ❌|1 ⚪|0ms|
|
|[fixtures/rspec-json.json](#user-content-r0)|1 ✅|1 ❌|1 ⚪|0ms|
|
||||||
|
|
|
||||||
|
|
@ -1,6 +1,7 @@
|
||||||

|
[](#user-content-test-report)
|
||||||
<details><summary>Expand for details</summary>
|
<details><summary>Expand for details</summary>
|
||||||
|
|
||||||
|
# <a name="user-content-test-report"></a> Tests report
|
||||||
|Report|Passed|Failed|Skipped|Time|
|
|Report|Passed|Failed|Skipped|Time|
|
||||||
|:---|---:|---:|---:|---:|
|
|:---|---:|---:|---:|---:|
|
||||||
|[fixtures/external/SilentNotes.trx](#user-content-r0)|67 ✅||12 ⚪|1s|
|
|[fixtures/external/SilentNotes.trx](#user-content-r0)|67 ✅||12 ⚪|1s|
|
||||||
|
|
|
||||||
|
|
@ -1,4 +1,5 @@
|
||||||

|
[](#user-content-test-report)
|
||||||
|
# <a name="user-content-test-report"></a> Tests report
|
||||||
|Report|Passed|Failed|Skipped|Time|
|
|Report|Passed|Failed|Skipped|Time|
|
||||||
|:---|---:|---:|---:|---:|
|
|:---|---:|---:|---:|---:|
|
||||||
|[fixtures/swift-xunit.xml](#user-content-r0)|2 ✅|1 ❌||220ms|
|
|[fixtures/swift-xunit.xml](#user-content-r0)|2 ✅|1 ❌||220ms|
|
||||||
|
|
|
||||||
3
dist/index.js
generated
vendored
3
dist/index.js
generated
vendored
|
|
@ -2023,7 +2023,7 @@ function getBadge(passed, failed, skipped, options) {
|
||||||
}
|
}
|
||||||
const hint = failed > 0 ? 'Tests failed' : 'Tests passed successfully';
|
const hint = failed > 0 ? 'Tests failed' : 'Tests passed successfully';
|
||||||
const uri = encodeURIComponent(`${options.badgeTitle}-${message}-${color}`);
|
const uri = encodeURIComponent(`${options.badgeTitle}-${message}-${color}`);
|
||||||
return ``;
|
return `[](#user-content-test-report)`;
|
||||||
}
|
}
|
||||||
function getTestRunsReport(testRuns, options) {
|
function getTestRunsReport(testRuns, options) {
|
||||||
const sections = [];
|
const sections = [];
|
||||||
|
|
@ -2032,6 +2032,7 @@ function getTestRunsReport(testRuns, options) {
|
||||||
sections.push(`<details><summary>Expand for details</summary>`);
|
sections.push(`<details><summary>Expand for details</summary>`);
|
||||||
sections.push(` `);
|
sections.push(` `);
|
||||||
}
|
}
|
||||||
|
sections.push('# <a name="user-content-test-report"></a> Tests report');
|
||||||
if (testRuns.length > 0 || options.onlySummary) {
|
if (testRuns.length > 0 || options.onlySummary) {
|
||||||
const tableData = testRuns
|
const tableData = testRuns
|
||||||
.map((tr, originalIndex) => ({ tr, originalIndex }))
|
.map((tr, originalIndex) => ({ tr, originalIndex }))
|
||||||
|
|
|
||||||
|
|
@ -146,7 +146,7 @@ function getBadge(passed: number, failed: number, skipped: number, options: Repo
|
||||||
}
|
}
|
||||||
const hint = failed > 0 ? 'Tests failed' : 'Tests passed successfully'
|
const hint = failed > 0 ? 'Tests failed' : 'Tests passed successfully'
|
||||||
const uri = encodeURIComponent(`${options.badgeTitle}-${message}-${color}`)
|
const uri = encodeURIComponent(`${options.badgeTitle}-${message}-${color}`)
|
||||||
return ``
|
return `[](#user-content-test-report)`
|
||||||
}
|
}
|
||||||
|
|
||||||
function getTestRunsReport(testRuns: TestRunResult[], options: ReportOptions): string[] {
|
function getTestRunsReport(testRuns: TestRunResult[], options: ReportOptions): string[] {
|
||||||
|
|
@ -157,6 +157,8 @@ function getTestRunsReport(testRuns: TestRunResult[], options: ReportOptions): s
|
||||||
sections.push(` `)
|
sections.push(` `)
|
||||||
}
|
}
|
||||||
|
|
||||||
|
sections.push('# <a name="user-content-test-report"></a> Tests report')
|
||||||
|
|
||||||
if (testRuns.length > 0 || options.onlySummary) {
|
if (testRuns.length > 0 || options.onlySummary) {
|
||||||
const tableData = testRuns
|
const tableData = testRuns
|
||||||
.map((tr, originalIndex) => ({tr, originalIndex}))
|
.map((tr, originalIndex) => ({tr, originalIndex}))
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue