-
Notifications
You must be signed in to change notification settings - Fork 16
82 lines (80 loc) · 2.88 KB
/
test.yml
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
73
74
75
76
77
78
79
80
81
82
name: tests
on:
push:
branches-ignore: [main]
workflow_dispatch:
jobs:
yarn-lockfile-check:
uses: salesforcecli/github-workflows/.github/workflows/lockFileCheck.yml@main
# Since the Windows unit tests take much longer, we run the linux unit tests first and then run the windows unit tests in parallel with NUTs
test-bundle:
runs-on: ubuntu-latest
name: test bundling
steps:
- uses: actions/checkout@v4
- uses: actions/setup-node@v4
with:
node-version: lts/*
cache: yarn
- uses: salesforcecli/github-workflows/.github/actions/yarnInstallWithRetries@main
- name: Build the project
run: yarn build
- name: check if bundling runs into failures
run: node scripts/testEsbuild.js
linux-unit-tests:
needs: yarn-lockfile-check
uses: salesforcecli/github-workflows/.github/workflows/unitTestsLinux.yml@main
windows-unit-tests:
needs: linux-unit-tests
uses: salesforcecli/github-workflows/.github/workflows/unitTestsWindows.yml@main
nuts:
needs: linux-unit-tests
uses: salesforcecli/github-workflows/.github/workflows/nut.yml@main
secrets: inherit
strategy:
matrix:
os: [ubuntu-latest, windows-latest]
fail-fast: false
with:
os: ${{ matrix.os }}
xNuts-ps:
needs: linux-unit-tests
uses: salesforcecli/github-workflows/.github/workflows/externalNut.yml@main
strategy:
fail-fast: false
matrix:
os: ['ubuntu-latest', 'windows-latest']
command:
- 'yarn test:nuts:tracking:basics'
- 'yarn test:nuts:tracking:conflicts'
- 'yarn test:nuts:tracking:forceignore'
- 'yarn test:nuts:tracking:remote'
- 'yarn test:nuts:tracking:lwc'
- 'yarn test:nuts:deb'
- 'yarn mocha "test/nuts/trackingCommands/mpd-*.nut.ts" --slow 3000 --timeout 600000 --parallel'
with:
packageName: '@salesforce/source-tracking'
externalProjectGitUrl: 'https://github.com/salesforcecli/plugin-source'
command: ${{matrix.command}}
os: ${{matrix.os}}
preSwapCommands: 'yarn upgrade @salesforce/source-deploy-retrieve@latest; npx yarn-deduplicate; yarn install'
useCache: false
secrets: inherit
xNuts-pdr:
needs: linux-unit-tests
uses: salesforcecli/github-workflows/.github/workflows/externalNut.yml@main
strategy:
fail-fast: false
matrix:
os: ['ubuntu-latest', 'windows-latest']
command:
- 'yarn test:nuts:tracking'
- 'yarn test:nuts:deb'
with:
packageName: '@salesforce/source-tracking'
externalProjectGitUrl: 'https://github.com/salesforcecli/plugin-deploy-retrieve'
command: ${{matrix.command}}
os: ${{matrix.os}}
preSwapCommands: 'yarn upgrade @salesforce/source-deploy-retrieve@latest; npx yarn-deduplicate; yarn install'
useCache: false
secrets: inherit