acceptance.yml: the release matrix on demand (Linux + Windows x node20/node22/bun, then the report); macOS results of 0.8.3 (123/123 on Node 20, Node 22, Bun) in docs/acceptance/, docs/acceptance.md generated
This commit is contained in:
parent
17883e1529
commit
9d6f741092
5 changed files with 4342 additions and 0 deletions
107
.forgejo/workflows/acceptance.yml
Normal file
107
.forgejo/workflows/acceptance.yml
Normal file
|
|
@ -0,0 +1,107 @@
|
|||
# The release acceptance matrix on demand (the same jobs as release.yml's acceptance + acceptance-report, which gate
|
||||
# every release): every user-facing command from the packed npm tarball on Linux and Windows x Node 20 / Node 22 / Bun,
|
||||
# then the markdown matrix (artifact storebound-acceptance). Run it from Actions > acceptance > Run workflow, or with
|
||||
# the API (POST /repos/{owner}/{repo}/actions/workflows/acceptance.yml/dispatches). macOS: tools/acceptance.ts on the Mac.
|
||||
name: acceptance
|
||||
|
||||
on:
|
||||
workflow_dispatch:
|
||||
|
||||
env:
|
||||
BUN_VERSION: '1.4.0'
|
||||
|
||||
jobs:
|
||||
acceptance:
|
||||
strategy:
|
||||
fail-fast: false
|
||||
matrix:
|
||||
include:
|
||||
- { os: ubuntu-22.04, platform: Linux, runtime: node, node: '20', name: node20 }
|
||||
- { os: ubuntu-22.04, platform: Linux, runtime: node, node: '22', name: node22 }
|
||||
- { os: ubuntu-22.04, platform: Linux, runtime: bun, node: '22', name: bun }
|
||||
- { os: windows, platform: Windows, runtime: node, node: '20', name: node20 }
|
||||
- { os: windows, platform: Windows, runtime: node, node: '22', name: node22 }
|
||||
- { os: windows, platform: Windows, runtime: bun, node: '22', name: bun }
|
||||
runs-on: ${{ matrix.os }}
|
||||
timeout-minutes: 45
|
||||
steps:
|
||||
- uses: actions/checkout@v4
|
||||
- uses: actions/setup-node@v4
|
||||
with:
|
||||
node-version: ${{ matrix.node }}
|
||||
- name: Bun (Linux)
|
||||
if: ${{ matrix.platform == 'Linux' }}
|
||||
shell: bash
|
||||
run: |
|
||||
curl -fsSL https://bun.sh/install | bash -s "bun-v${BUN_VERSION}" >/dev/null
|
||||
echo "$HOME/.bun/bin" >> "${FORGEJO_PATH:-$GITHUB_PATH}"
|
||||
- name: Acceptance matrix (Linux)
|
||||
if: ${{ matrix.platform == 'Linux' }}
|
||||
shell: bash
|
||||
run: |
|
||||
node --version && bun --version
|
||||
bun tools/acceptance.ts run --runtime ${{ matrix.runtime }} --platform Linux --jobs 4 --out acceptance/Linux-${{ matrix.name }}.json
|
||||
- name: Acceptance matrix (Windows)
|
||||
if: ${{ matrix.platform == 'Windows' }}
|
||||
shell: pwsh
|
||||
run: |
|
||||
node --version; bun --version
|
||||
bun tools/acceptance.ts run --runtime ${{ matrix.runtime }} --platform Windows --jobs 3 --out acceptance/Windows-${{ matrix.name }}.json
|
||||
if ($LASTEXITCODE -ne 0) { throw "acceptance matrix: red cells" }
|
||||
- uses: actions/upload-artifact@v3
|
||||
if: ${{ always() }}
|
||||
with:
|
||||
name: acceptance-${{ matrix.platform }}-${{ matrix.name }}
|
||||
path: acceptance/
|
||||
retention-days: 30
|
||||
|
||||
acceptance-report:
|
||||
needs: [acceptance]
|
||||
if: ${{ always() }}
|
||||
runs-on: ubuntu-22.04
|
||||
timeout-minutes: 10
|
||||
steps:
|
||||
- uses: actions/checkout@v4
|
||||
- uses: actions/download-artifact@v3
|
||||
continue-on-error: true
|
||||
with:
|
||||
name: acceptance-Linux-node20
|
||||
path: acceptance-runs/Linux-node20
|
||||
- uses: actions/download-artifact@v3
|
||||
continue-on-error: true
|
||||
with:
|
||||
name: acceptance-Linux-node22
|
||||
path: acceptance-runs/Linux-node22
|
||||
- uses: actions/download-artifact@v3
|
||||
continue-on-error: true
|
||||
with:
|
||||
name: acceptance-Linux-bun
|
||||
path: acceptance-runs/Linux-bun
|
||||
- uses: actions/download-artifact@v3
|
||||
continue-on-error: true
|
||||
with:
|
||||
name: acceptance-Windows-node20
|
||||
path: acceptance-runs/Windows-node20
|
||||
- uses: actions/download-artifact@v3
|
||||
continue-on-error: true
|
||||
with:
|
||||
name: acceptance-Windows-node22
|
||||
path: acceptance-runs/Windows-node22
|
||||
- uses: actions/download-artifact@v3
|
||||
continue-on-error: true
|
||||
with:
|
||||
name: acceptance-Windows-bun
|
||||
path: acceptance-runs/Windows-bun
|
||||
- name: Matrix (markdown), red cells fail the job
|
||||
run: |
|
||||
curl -fsSL https://bun.sh/install | bash -s "bun-v${BUN_VERSION}" >/dev/null
|
||||
export PATH="$HOME/.bun/bin:$PATH"
|
||||
V=$(bun tools/desktop-version.ts --print)
|
||||
mkdir -p out
|
||||
bun tools/acceptance.ts report acceptance-runs docs/acceptance --md "out/storebound_${V}_acceptance.md" --expect 7 --strict
|
||||
- uses: actions/upload-artifact@v3
|
||||
if: ${{ always() }}
|
||||
with:
|
||||
name: storebound-acceptance
|
||||
path: out/
|
||||
retention-days: 30
|
||||
Loading…
Add table
Add a link
Reference in a new issue