-
-
Notifications
You must be signed in to change notification settings - Fork 5
80 lines (71 loc) · 2.58 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
name: Tests
on:
pull_request:
branches: [main]
workflow_dispatch:
jobs:
test:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@b4ffde65f46336ab88eb53be808477a3936bae11
- name: Use Node.js 16.10.x
uses: actions/setup-node@60edb5dd545a775178f52524783378180af0d1f8
with:
node-version: 16.10.x
- run: npm ci
- run: npm run build
- run: npm run test:src
test_18:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@b4ffde65f46336ab88eb53be808477a3936bae11
- name: Use Node.js 18.x
uses: actions/setup-node@60edb5dd545a775178f52524783378180af0d1f8
with:
node-version: 18.x
- run: npm ci
- run: npm run build
- name: Run npm run test:src
run: npm run test:src -- --coverage=false
integration:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@b4ffde65f46336ab88eb53be808477a3936bae11
- name: Use Node.js 16.10.x (earliest version supported)
uses: actions/setup-node@60edb5dd545a775178f52524783378180af0d1f8
with:
node-version: 16.10.x
- run: npm ci
- run: npm run build
- run: npm run test:e2e
env:
CI: true
NODE_ENV: "test"
DISCORD_TOKEN: ${{ secrets.DISCORD_TOKEN }}
SOUNDCLOUD_API_KEY: ${{ secrets.SOUNDCLOUD_API_KEY }}
CORDE_TEST_TOKEN: ${{ secrets.CORDE_TEST_TOKEN }}
CORDE_BOT_ID: ${{ secrets.CORDE_BOT_ID }}
BOT_TEST_ID: ${{ secrets.BOT_TEST_ID }}
GUILD_ID: ${{ secrets.GUILD_ID }}
CHANNEL_ID: ${{ secrets.CHANNEL_ID }}
QUEUE_CHANNEL_ID: ${{ secrets.QUEUE_CHANNEL_ID }}
QUEUE_ADMIN_ROLE_ID: ${{ secrets.QUEUE_ADMIN_ROLE_ID }}
QUEUE_CREATOR_ROLE_ID: ${{ secrets.QUEUE_CREATOR_ROLE_ID }}
BOT_PREFIX: "?"
# Try again with the minified build
- run: npm run build --production
- run: npm run test:e2e
env:
CI: true
NODE_ENV: "test"
DISCORD_TOKEN: ${{ secrets.DISCORD_TOKEN }}
SOUNDCLOUD_API_KEY: ${{ secrets.SOUNDCLOUD_API_KEY }}
CORDE_TEST_TOKEN: ${{ secrets.CORDE_TEST_TOKEN }}
CORDE_BOT_ID: ${{ secrets.CORDE_BOT_ID }}
BOT_TEST_ID: ${{ secrets.BOT_TEST_ID }}
GUILD_ID: ${{ secrets.GUILD_ID }}
CHANNEL_ID: ${{ secrets.CHANNEL_ID }}
QUEUE_CHANNEL_ID: ${{ secrets.QUEUE_CHANNEL_ID }}
QUEUE_ADMIN_ROLE_ID: ${{ secrets.QUEUE_ADMIN_ROLE_ID }}
QUEUE_CREATOR_ROLE_ID: ${{ secrets.QUEUE_CREATOR_ROLE_ID }}
BOT_PREFIX: "?"