Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
35 changes: 35 additions & 0 deletions .github/actions/ecosystem-run/action.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,35 @@
name: Ecosystem Run
description: Run ecosystem CI with specific test suite
inputs:
version:
required: true
description: "@webcontainer/api version to use"
test-suite:
required: true
description: Test suite to run

runs:
using: composite

steps:
- uses: actions/setup-node@v4
id: setup-node
continue-on-error: true
with:
node-version: 20

- run: corepack enable
shell: bash

- run: pnpm --version
shell: bash

- run: pnpm i --frozen-lockfile
shell: bash

- run: >-
pnpm run test
--release ${{ inputs.version }}
${{ inputs.test-suite }}
id: ecosystem-ci-run
shell: bash
41 changes: 26 additions & 15 deletions .github/workflows/ecosystem-ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -16,35 +16,46 @@ on:
required: true
type: string
default: "latest"
suite:
description: "testsuite to run"
type: choice
default: "all"
options:
- all
- starters
- vitest-in-webcontainer
- webcontainer-test

jobs:
test-ecosystem:
if: inputs.suite == 'all'
timeout-minutes: 60
runs-on: ubuntu-latest
strategy:
fail-fast: false
matrix:
suite:
- starters
- vitest-in-webcontainer
- webcontainer-test
fail-fast: false
steps:
- uses: actions/checkout@v4

- uses: actions/setup-node@v4
- name: Run ${{ matrix.suite }}
uses: ./.github/actions/ecosystem-run
with:
node-version: 20
id: setup-node
continue-on-error: true

- run: corepack enable
test-suite: ${{ matrix.suite }}
version: ${{ inputs.version || github.event.client_payload.version }}

- run: pnpm --version

- run: pnpm i --frozen-lockfile
test-ecosystem-selected:
if: inputs.suite != 'all'
timeout-minutes: 60
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4

- run: >-
pnpm run test
--release ${{ inputs.version || github.event.client_payload.version }}
${{ matrix.suite }}
id: ecosystem-ci-run
- name: Run ${{ inputs.suite }}
uses: ./.github/actions/ecosystem-run
with:
test-suite: ${{ inputs.suite }}
version: ${{ inputs.version || github.event.client_payload.version }}