-
-
Notifications
You must be signed in to change notification settings - Fork 1.8k
72 lines (61 loc) · 1.81 KB
/
e2e-test.yml
File metadata and controls
72 lines (61 loc) · 1.81 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
name: E2E Test
on:
workflow_dispatch:
push:
branches:
- next
paths-ignore:
- '**/*.md'
pull_request:
branches:
- next
concurrency:
group: ${{ github.workflow }}-${{ github.sha }}
cancel-in-progress: ${{ github.ref_name != 'next' }}
defaults:
run:
shell: bash
jobs:
e2e-test:
name: ${{ matrix.project.name }} E2E test
permissions:
contents: read
packages: read
runs-on: ubuntu-latest
strategy:
fail-fast: false
matrix:
project:
- name: cnpmcore
node-version: 24
command: |
npm install
npm run typecheck
npm run build
npm run prepublishOnly
steps:
- uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4
- uses: ./.github/actions/clone
with:
ecosystem-ci-project: ${{ matrix.project.name }}
- name: Install pnpm
uses: pnpm/action-setup@41ff72655975bd51cab0327fa583b6e92b6d3061 # v4
- name: Set up Node.js
uses: actions/setup-node@395ad3262231945c25e8478fd5baf05154b1d79f # v6
with:
node-version: ${{ matrix.project.node-version }}
cache: 'pnpm'
- name: Install dependencies
run: pnpm install --frozen-lockfile
- name: Build all packages
run: pnpm build
- name: Pack packages into tgz
run: |
pnpm -r pack
- name: Override dependencies from tgz in ${{ matrix.project.name }}
working-directory: ecosystem-ci/${{ matrix.project.name }}
run: |
node ../patch-project.ts ${{ matrix.project.name }}
- name: Run e2e test commands in ${{ matrix.project.name }}
working-directory: ecosystem-ci/${{ matrix.project.name }}
run: ${{ matrix.project.command }}