-
Notifications
You must be signed in to change notification settings - Fork 0
96 lines (90 loc) · 2.59 KB
/
sloth_tests.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
87
88
89
90
91
92
93
94
95
96
name: sloth_tests
on:
pull_request:
push:
branches:
- main
jobs:
analyze:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
- uses: subosito/flutter-action@v2
with:
channel: 'stable'
- name: "Install Tools"
run: ./.github/workflows/scripts/install-tools.sh
- name: "Analyze"
uses: invertase/github-action-dart-analyzer@v1
with:
fatal-infos: true
fatal-warnings: true
# This job ensures `melos` compiles and runs fine on the
# minimum Dart SDK version that it supports.
dart_version:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
- uses: dart-lang/setup-dart@v1
with:
sdk: 2.18.0 # Update when min sdk supported version of `melos` package changes.
- name: "Run Melos"
run: ./.github/workflows/scripts/install-tools.sh
format:
runs-on: ubuntu-latest
timeout-minutes: 10
steps:
- uses: actions/checkout@v2
- uses: subosito/flutter-action@v2
with:
channel: 'stable'
- name: "Install Tools"
run: ./.github/workflows/scripts/install-tools.sh
- name: "Check formatting"
run: melos format-check
test_linux:
runs-on: ubuntu-latest
timeout-minutes: 25
steps:
- uses: actions/checkout@v2
with:
fetch-depth: 0
- uses: subosito/flutter-action@v2
with:
channel: 'stable'
- name: "Install Tools"
run: ./.github/workflows/scripts/install-tools.sh
- name: "Run Tests"
run: melos test --no-select
test_macos:
runs-on: macos-latest
timeout-minutes: 25
steps:
- uses: actions/checkout@v2
with:
fetch-depth: 0
- uses: subosito/flutter-action@v2
with:
channel: 'stable'
- name: "Install Tools"
run: ./.github/workflows/scripts/install-tools.sh
- name: "Run Tests"
run: melos test --no-select
test_windows:
runs-on: windows-latest
timeout-minutes: 10
steps:
- uses: actions/checkout@v2
with:
fetch-depth: 0
- uses: subosito/flutter-action@v2
with:
channel: 'stable'
- name: "Install Tools"
run: .\.github\workflows\scripts\install-tools.bat
- name: "Run Tests"
# TODO: Figure out why invoking Melos via PowerShell doesn't work properly.
# When using PowerShell, the exit code is not propagated correctly.
# Even running `CMD /C melos ...` from PowerShell does not work.
shell: cmd
run: melos test --no-select