cc-haha/scripts/pr/release-workflow.test.ts
程序员阿江(Relakkes) 460a245fb2 test: update release workflow preflight assertion for coverage skip
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-05-09 00:07:22 +08:00

17 lines
797 B
TypeScript

import { describe, expect, test } from 'bun:test'
import { readFileSync } from 'node:fs'
describe('release desktop workflow', () => {
test('runs a quality preflight before packaging matrix builds', () => {
const workflow = readFileSync('.github/workflows/release-desktop.yml', 'utf8')
expect(workflow).toContain('quality-preflight:')
expect(workflow).toContain('run: bun run quality:gate --mode pr --skip coverage --artifacts-dir artifacts/quality-runs')
expect(workflow).toContain('cat "$latest_report" >> "$GITHUB_STEP_SUMMARY"')
expect(workflow).toContain('name: release-quality-gate')
expect(workflow).toContain('path: artifacts/quality-runs/')
expect(workflow).toContain('retention-days: 14')
expect(workflow).toContain('needs: quality-preflight')
})
})