-
Notifications
You must be signed in to change notification settings - Fork 2
53 lines (48 loc) · 1.17 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
# SPDX-FileCopyrightText: 2023 Firebot Gambling Script Contributors
#
# SPDX-License-Identifier: EUPL-1.2
name: Test
on:
push:
branches: [main, staging, trying]
pull_request:
branches: [main]
merge_group:
env:
CI: true
node: 'lts/*'
jobs:
build:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- name: Use Node.js ${{ env.node }}
uses: actions/setup-node@v4
with:
node-version: ${{ env.node }}
cache: 'npm'
- name: Install Dependencies
run: npm install
- name: TypeScript Test
run: npm run test:coverage --ci
- name: Annotate Client Test Results
uses: mikepenz/action-junit-report@v4.3.1
if: always()
with:
report_paths: 'junit.xml'
style:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- name: Use Node.js ${{ env.node }}
uses: actions/setup-node@v4
with:
node-version: ${{ env.node }}
cache: 'npm'
- name: Install Dependencies
run: npm install
- name: TypeScript Formatting
run: npm run prettier:check
- name: TypeScript Code Style
run: npm run lint
if: success() || failure()