mirror of
https://github.com/GeWuYou/GFramework.git
synced 2026-03-22 10:34:30 +08:00
feat(ci): 集成测试报告生成和发布功能
新增DotnetCtrfJsonReporter工具来生成JSON格式的测试报告, 并添加GitHub测试报告发布步骤,支持PR报告、摘要对比、 洞察分析、易失率、失败率和最慢测试等多维度报告展示。
This commit is contained in:
parent
f2b3c8663e
commit
cfef1e1d03
15
.github/workflows/ci.yml
vendored
15
.github/workflows/ci.yml
vendored
@ -64,6 +64,7 @@ jobs:
|
||||
--no-build \
|
||||
--logger trx \
|
||||
--results-directory TestResults
|
||||
dotnet tool run DotnetCtrfJsonReporter -t "TestResults/testResults.trx"
|
||||
|
||||
# 生成并发布测试报告,无论测试成功或失败都会执行
|
||||
- name: Test Report
|
||||
@ -73,3 +74,17 @@ jobs:
|
||||
name: .NET Test Results
|
||||
path: TestResults/*.trx
|
||||
reporter: dotnet-trx
|
||||
- name: Publish Test Report
|
||||
uses: ctrf-io/github-test-reporter@v1
|
||||
with:
|
||||
report-path: './ctrf/*.json'
|
||||
github-report: true
|
||||
pull-request-report: true
|
||||
summary-delta-report: true
|
||||
insights-report: true
|
||||
flaky-rate-report: true
|
||||
fail-rate-report: true
|
||||
slowest-report: true
|
||||
env:
|
||||
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
|
||||
if: always()
|
||||
Loading…
x
Reference in New Issue
Block a user