修复了pr评论里错误的url (#19)
All checks were successful
DevStar Studio CI/CD Pipeline / build-and-push-x86-64-docker-image (push) Successful in 18m44s

修改了测试脚本的触发形式,在pr的时候触发

Reviewed-on: #19
Co-authored-by: 24焦俊鸣 <13763605353@163.com>
Co-committed-by: 24焦俊鸣 <13763605353@163.com>
This commit is contained in:
24焦俊鸣
2025-12-13 10:15:55 +00:00
committed by devstar-gitee
parent 8e34179926
commit a49636ad31
2 changed files with 6 additions and 10 deletions

View File

@@ -21,9 +21,6 @@
name: DevStar Studio Auto Test Pipeline
on:
push:
branches:
- main
pull_request:
branches:
- main

View File

@@ -1,8 +1,5 @@
name: DevStar E2E Test
on:
push:
branches:
- main
pull_request:
branches:
- main
@@ -56,10 +53,12 @@ jobs:
github-token: ${{ github.token }}
script: |
const testResult = process.env.TEST_RESULT || '未知';
const isSuccess = testResult === 'success';
// 动态生成构建链接
const runUrl = `${context.payload.repository.html_url}/actions/runs/${context.runId}`;
const isSuccess = testResult === 'success';
const serverUrl = process.env.GITHUB_SERVER_URL;
const repo = process.env.GITHUB_REPOSITORY;
const runId = process.env.GITHUB_RUN_NUMBER;
const runUrl = `${serverUrl}/${repo}/actions/runs/${runId}`;
console.log(`生成报告链接: ${runUrl}`);
const comment = `
## 📋 E2E 测试结果报告