Files
hyperframes/.github/workflows/windows-render.yml

76 lines
2.7 KiB
YAML

name: Windows render verification
permissions:
contents: read
# Suppress hyperframes CLI telemetry from HeyGen's own CI runs.
# External users' CI continues to emit telemetry unless they set this themselves.
env:
HYPERFRAMES_NO_TELEMETRY: "1"
# Manually triggered smoke test that renders a HyperFrames composition on a
# real Windows runner. Proves the PR #336 `where ffmpeg` fix actually works
# end-to-end: FFmpeg is discovered natively on Windows, Chrome is installed
# and launched, frames are captured, and an MP4 is produced — without Docker
# or WSL.
on:
merge_group:
types: [checks_requested]
pull_request:
# `edited` is required so the workflow re-fires when a PR's base ref is
# set back to `main` after a Graphite stack restack momentarily flips
# the base off of `main`. Without it, `pull_request` triggers are not
# re-evaluated on `base_ref_changed`, leaving required checks skipped
# for that head SHA forever.
types: [opened, synchronize, reopened, edited]
branches: [main]
push:
branches: [main]
workflow_dispatch:
inputs:
ref:
description: "Git ref to render (branch / tag / SHA)."
required: false
default: ""
jobs:
loop:
name: slowScript loop
runs-on: windows-latest
timeout-minutes: 40
steps:
- name: Disable Windows Defender real-time monitoring
shell: pwsh
continue-on-error: true
run: Set-MpPreference -DisableRealtimeMonitoring $true
- uses: actions/checkout@11d5960a326750d5838078e36cf38b85af677262 # v4
with:
ref: ${{ inputs.ref || github.sha }}
- uses: ./.github/actions/install-ffmpeg-windows
- uses: oven-sh/setup-bun@0c5077e51419868618aeaa5fe8019c62421857d6 # v2
- uses: actions/setup-node@49933ea5288caeca8642d1e84afbd3f7d6820020 # v4
with:
node-version: 22
- name: Install
shell: pwsh
run: bun install --frozen-lockfile --linker=hoisted
- name: Build prerequisites
shell: pwsh
run: |
bun run --filter '@hyperframes/{parsers,lint,studio-server}' build
bun run --cwd packages/core build
- name: Prepare browser
shell: pwsh
run: node --import tsx packages/cli/scripts/prepare-process-test-browser.mjs
- name: Loop the browser tests with two workers
shell: pwsh
timeout-minutes: 32
run: |
Set-Location packages/cli
for ($i = 1; $i -le 8; $i++) {
Write-Host "=== run $i"
bunx vitest run browser.test --maxWorkers=2 --reporter=verbose 2>&1 | Tee-Object -FilePath "../../run-$i.log" | Select-String -Pattern "NAVDIAG|ERR_ABORTED|slowScript|Test Files|Tests " | ForEach-Object { $_.Line }
}