Skip to content

Commit 5f2d71a

Browse files
committed
Update tests-changed report formatting and restore summary integration
1 parent d5357b5 commit 5f2d71a

File tree

5 files changed

+17
-17
lines changed

5 files changed

+17
-17
lines changed

dist/index.js

Lines changed: 4 additions & 4 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

dist/index.js.map

Lines changed: 1 addition & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

dist/reports/tests-changed-table.hbs

Lines changed: 2 additions & 2 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

src/github/core.ts

Lines changed: 8 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -243,14 +243,6 @@ function generateReportByType(
243243
core.info('Adding summary delta report to summary')
244244
addViewToSummary('### Summary', BuiltInReports.SummaryDeltaTable, report)
245245
break
246-
case 'tests-changed-report':
247-
core.info('Adding tests changed report to summary')
248-
addViewToSummary(
249-
'### Test Changes',
250-
BuiltInReports.TestsChangedTable,
251-
report
252-
)
253-
break
254246
case 'github-report':
255247
core.info('Adding GitHub report to summary')
256248
addViewToSummary('### Test Results', BuiltInReports.GitHub, report)
@@ -331,6 +323,14 @@ function generateReportByType(
331323
core.info('No AI analysis to display, skipping ai-report')
332324
}
333325
break
326+
case 'tests-changed-report':
327+
core.info('Adding tests changed report to summary')
328+
addViewToSummary(
329+
'### Test Changes',
330+
BuiltInReports.TestsChangedTable,
331+
report
332+
)
333+
break
334334
case 'pull-request-report':
335335
core.info('Adding pull request report to summary')
336336
addViewToSummary('', BuiltInReports.PullRequest, report)

src/reports/tests-changed-table.hbs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@
66
| **Name** | **Suite** |
77
| --- | --- |
88
{{#each report.insights.extra.testsAdded}}
9-
| {{name}}{{#if filePath}} <sub><a href="{{../github.repository.htmlUrl}}/blob/{{#if ../github.context.pull_request.head.sha}}{{../github.context.pull_request.head.sha}}{{else}}{{#if ../ctrf.environment.branchName}}{{../ctrf.environment.branchName}}{{else}}{{../github.context.ref}}{{/if}}{{/if}}/{{filePath}}{{#if line}}#L{{line}}{{/if}}">view</a></sub>{{/if}} | {{#if suite}}{{join suite " > "}}{{else}}-{{/if}} |
9+
| {{name}} | {{#if suite}}{{join suite " > "}}{{else}}-{{/if}} |
1010
{{/each}}
1111
{{/if}}
1212

@@ -16,7 +16,7 @@
1616
| **Name** | **Suite** |
1717
| --- | --- |
1818
{{#each report.insights.extra.testsRemoved}}
19-
| {{name}}{{#if filePath}} <sub><a href="{{../github.repository.htmlUrl}}/blob/{{#if ../github.context.pull_request.head.sha}}{{../github.context.pull_request.head.sha}}{{else}}{{#if ../ctrf.environment.branchName}}{{../ctrf.environment.branchName}}{{else}}{{../github.context.ref}}{{/if}}{{/if}}/{{filePath}}{{#if line}}#L{{line}}{{/if}}">view</a></sub>{{/if}} | {{#if suite}}{{join suite " > "}}{{else}}-{{/if}} |
19+
| {{name}} | {{#if suite}}{{join suite " > "}}{{else}}-{{/if}} |
2020
{{/each}}
2121
{{/if}}
2222

0 commit comments

Comments
 (0)