| 
1 | 1 | name: Run JS tests  | 
2 |  | - | 
3 |  | -# 3 different jobs are not combined into 1.  | 
4 |  | -# In theory, it could be less error-prone:  | 
5 |  | -# 1. Chokidar does huge load of IO / FS.  | 
6 |  | -# 2. Github CI use virtual machines which can reuse single physical machine.  | 
7 |  | -# 3. If same physical machine has too much IO usage, we have more chance of bugs.  | 
8 |  | - | 
9 | 2 | on:  | 
10 | 3 |   - push  | 
11 | 4 |   - pull_request  | 
12 | 5 | jobs:  | 
13 |  | -  lint:  | 
14 |  | -    name: Lint  | 
15 |  | -    runs-on: ubuntu-latest  | 
16 |  | -    steps:  | 
17 |  | -      - uses: actions/checkout@1e31de5234b9f8995739874a8ce0492dc87873e2 # v4  | 
18 |  | -      - uses: actions/setup-node@8f152de45cc393bb48ce5d89d36b731f54556e65 # v4  | 
19 |  | -        with:  | 
20 |  | -          registry-url: 'https://registry.npmjs.org'  | 
21 |  | -          cache: npm  | 
22 |  | -      - run: npm install  | 
23 |  | -      - run: npm run build --if-present  | 
24 |  | -      - run: npm run lint --if-present  | 
25 |  | -  node:  | 
26 |  | -    name: Node v${{ matrix.version }} @ ${{ matrix.os }}  | 
27 |  | -    runs-on: ${{ matrix.os }}  | 
 | 6 | +  test-js:  | 
 | 7 | +    name: 'jsbt v0.4.1'  | 
 | 8 | +    uses: paulmillr/jsbt/.github/workflows/test-js.yml@2318b9efe24831b4bd4cadf720c96f071c69c64d  | 
28 | 9 |     strategy:  | 
29 |  | -      fail-fast: false  | 
30 | 10 |       matrix:  | 
31 |  | -        version: [18, 20, 22, 24]  | 
32 | 11 |         os: [ubuntu-latest, windows-latest, macOS-latest]  | 
33 |  | -    steps:  | 
34 |  | -      - uses: actions/checkout@1e31de5234b9f8995739874a8ce0492dc87873e2 # v4  | 
35 |  | -      - name: Use Node.js ${{ matrix.version }}  | 
36 |  | -        uses: actions/setup-node@8f152de45cc393bb48ce5d89d36b731f54556e65 # v4  | 
37 |  | -        with:  | 
38 |  | -          node-version: ${{ matrix.version }}  | 
39 |  | -      - run: npm install  | 
40 |  | -      - run: npm run build --if-present  | 
41 |  | -      - run: npm test  | 
42 |  | -  bun:  | 
43 |  | -    needs: node  | 
44 |  | -    name: Bun  | 
45 |  | -    runs-on: macOS-latest  | 
46 |  | -    steps:  | 
47 |  | -      - uses: actions/checkout@1e31de5234b9f8995739874a8ce0492dc87873e2 # v4  | 
48 |  | -      - uses: oven-sh/setup-bun@4bc047ad259df6fc24a6c9b0f9a0cb08cf17fbe5 # v2.0.1  | 
49 |  | -      - run: bun install  | 
50 |  | -      - run: bun run build  | 
51 |  | -      - run: bun run test:bun  | 
 | 12 | +    with:  | 
 | 13 | +      runs-on: ${{ matrix.os }}  | 
0 commit comments