-
Notifications
You must be signed in to change notification settings - Fork 18
55 lines (45 loc) · 1.45 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
name: Run tests
on:
push:
branches:
- main
- 'release/**'
pull_request:
branches:
- '**'
# Cancel running jobs from previous pipelines of the same workflow on PR to save resource when commits are pushed quickly
# NOTE: we don't want this behavior on default branch
# See https://stackoverflow.com/a/68422069
concurrency:
group: ${{ github.ref == 'refs/heads/main' && format('ci-default-branch-{0}-{1}', github.sha, github.workflow) || format('ci-pr-{0}-{1}', github.ref, github.workflow) }}
cancel-in-progress: true
jobs:
build:
name: Build
runs-on: ubuntu-latest
steps:
- name: Configure git
run: |
git config --global committer.email "[email protected]"
git config --global committer.name "FINOS Admin"
git config --global author.email "${GITHUB_ACTOR}@users.noreply.github.com"
git config --global author.name "${GITHUB_ACTOR}"
- name: Checkout code
uses: actions/[email protected]
- name: Setup Node
uses: actions/[email protected]
with:
node-version: 20
- name: Set up JDK
uses: actions/setup-java@v4
with:
distribution: 'temurin'
java-version: 21
java-package: jdk
- name: Install dependencies
run: |
npm install
npm install -g @vscode/vsce
- name: Run tests
run: |
xvfb-run -a npm run test