-
Notifications
You must be signed in to change notification settings - Fork 14
86 lines (82 loc) · 2.3 KB
/
mjolnir.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
83
84
85
86
# SPDX-FileCopyrightText: 2024 Gnuxie <[email protected]>
#
# SPDX-License-Identifier: CC0-1.0
name: Tests
on:
push:
branches: [main]
pull_request:
branches: [main]
schedule:
- cron: "20 20 * * *"
env:
CARGO_TERM_COLOR: always
jobs:
build:
name: Build & Lint
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- name: Specifically use node 20 like in the readme.
uses: actions/setup-node@v4
with:
node-version: "20"
- run: corepack enable
- run: corepack yarn install
- run: corepack yarn build
- run: corepack yarn lint
unit:
name: Unit tests
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- name: Specifically use node 20 like in the readme.
uses: actions/setup-node@v4
with:
node-version: "20"
- run: corepack yarn install
- run: corepack yarn test:unit
integration:
name: Integration tests
runs-on: ubuntu-latest
timeout-minutes: 60
steps:
- uses: actions/checkout@v4
- uses: actions/setup-node@v4
with:
node-version: "20"
- name: Fetch and build mx-tester (cached across runs)
uses: baptiste0928/cargo-install@v3
with:
crate: mx-tester
version: "0.3.3"
- name: Setup image
run: RUST_LOG=debug,hyper=info,rusttls=info mx-tester build up
- name: Setup dependencies
run: corepack yarn install
- name: Run tests
run: RUST_LOG=debug,hyper=info,rusttls=info mx-tester run
- name: Cleanup
run: mx-tester down
appservice-integration:
name: Application Service Integration tests
runs-on: ubuntu-latest
timeout-minutes: 30
steps:
- uses: actions/checkout@v4
- uses: actions/setup-node@v4
with:
node-version: "20"
- name: Fetch and build mx-tester (cached across runs)
uses: baptiste0928/cargo-install@v3
with:
crate: mx-tester
version: "0.3.3"
- name: Setup image
run: RUST_LOG=debug,hyper=info,rusttls=info mx-tester build up
- name: Setup dependencies
run: corepack yarn install
- name: Run tests
run: corepack yarn test:appservice:integration
- name: Cleanup
run: mx-tester down