Files
hyperframes/.github/actions/setup-test-workspace/action.yml
T
Miguel Ángel 3bb0a9a5b5 perf(engine): skip the screenshot on frames the page reports unchanged in beginframe capture (#7027)
* perf(engine): skip the screenshot on frames the page reports unchanged in beginframe capture

* fix(engine): beginframe reuse never returns a frame older than a cross-frame page change

* fix(engine): the BeginFrame reuse test gets a headless shell in the flake gate

* fix(ci): run the headless shell installer through its package

* fix(ci): install the headless shell with bunx, npx finds no bin in the workspace
2026-11-02 19:17:31 +00:00

52 lines
2.0 KiB
YAML

name: Set up the test workspace
description: Bun, Node, FFmpeg, Chrome, dependencies and the package builds the Linux test jobs need.
inputs:
chrome:
description: Install Chrome (path in the chrome-path output).
default: "false"
engine:
description: Build @hyperframes/engine.
default: "false"
headless-shell:
description: Install chrome-headless-shell (path in the headless-shell-path output), the only build with BeginFrame.
default: "false"
outputs:
chrome-path:
description: Path of the installed Chrome, when `chrome` is true.
value: ${{ steps.chrome.outputs.chrome-path }}
headless-shell-path:
description: Path of chrome-headless-shell, when `headless-shell` is true.
value: ${{ steps.shell.outputs.path }}
runs:
using: composite
steps:
- uses: oven-sh/setup-bun@0c5077e51419868618aeaa5fe8019c62421857d6 # v2
- uses: actions/setup-node@49933ea5288caeca8642d1e84afbd3f7d6820020 # v4
with:
node-version: 22
- uses: ./.github/actions/install-ffmpeg-linux
- uses: ./.github/actions/prepare-ffmpeg-bin
- id: chrome
if: inputs.chrome == 'true'
uses: browser-actions/setup-chrome@c785b87e244131f27c9f19c1a33e2ead956ab7ce # v1
with:
chrome-version: stable
- shell: bash
run: bash scripts/ci/install-workspace-dependencies.sh
- id: shell
if: inputs.headless-shell == 'true'
shell: bash
run: |
dir="$RUNNER_TEMP/headless-shell"
bunx @puppeteer/browsers@3.2.2 install chrome-headless-shell@stable --path "$dir"
echo "path=$(find "$dir" -type f -name chrome-headless-shell | head -n 1)" >> "$GITHUB_OUTPUT"
- shell: bash
run: bun run --filter '@hyperframes/{parsers,lint,studio-server}' build
- shell: bash
run: bun run --cwd packages/core build
- shell: bash
run: bun run --cwd packages/core build:hyperframes-runtime
- if: inputs.engine == 'true'
shell: bash
run: bun run --filter @hyperframes/engine build