cloud-drive-renamer/.github/workflows/complete-tests.yml

72 行
1.7 KiB
YAML

此文件含有模棱两可的 Unicode 字符

此文件含有可能会与其他字符混淆的 Unicode 字符。 如果您是想特意这样的,可以安全地忽略该警告。 使用 Escape 按钮显示他们。

# ==========================================
# GitHub Actions Workflow: Complete Test Suite
# ==========================================
#
# 功能:运行完整的测试套件(包括性能测试)
#
# 触发条件:
# - 手动触发
# - 每周定时运行
# - Release 标签
#
# 时长:约 5-10 分钟
#
# ==========================================
name: Complete Tests
# 触发条件
on:
# 手动触发
workflow_dispatch:
# 每周一早上运行
schedule:
- cron: '0 0 * * 1'
# 注意:tag 推送时只触发 release.yml
# 本工作流专用于定时运行和手动触发
# 环境变量
env:
NODE_VERSION: '20'
jobs:
complete-tests:
name: Complete Test Suite
runs-on: ubuntu-latest
timeout-minutes: 15
steps:
- name: 📥 Checkout repository
uses: actions/checkout@v4
- name: 📦 Setup pnpm
uses: pnpm/action-setup@v4
- name: 🔧 Setup Node.js
uses: actions/setup-node@v4
with:
node-version: ${{ env.NODE_VERSION }}
cache: 'pnpm'
- name: 📦 Install dependencies
run: pnpm install --frozen-lockfile
# 运行完整的质量检查和测试
- name: 🚀 Run complete CI suite
run: pnpm run ci
continue-on-error: false
# 可选:运行 E2E 测试
- name: 🎭 Run E2E tests
run: pnpm run test:e2e
continue-on-error: true # E2E 测试失败不阻止流程
- name: ✅ All tests completed
run: |
echo "✅ Complete test suite passed!"
echo "- ✅ Quality checks (lint, typecheck, tests)"
echo "- ✅ Build verification"
echo "- 🎭 E2E tests (optional)"