-
Notifications
You must be signed in to change notification settings - Fork 284
113 lines (99 loc) · 2.48 KB
/
ci.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
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
# Run Vibe.d's test suite on all three platforms
name: CI
on: [push, pull_request]
jobs:
main:
name: Run
strategy:
fail-fast: false
matrix:
os:
- ubuntu-latest
dc:
- dmd-latest
- dmd-2.097.1
- dmd-2.096.1
- dmd-2.093.1
- dmd-2.091.1
- ldc-latest
- ldc-1.27.1
- ldc-1.26.0
- ldc-1.23.0
- ldc-1.21.0
parts:
- 'builds,unittests,examples,tests,redis'
extra_dflags:
- ''
include:
# Custom part for coverage
- { os: ubuntu-latest, dc: dmd-latest, parts: 'unittests,tests', extra_dflags: "-cov -version=VibedSetCoverageMerge" }
runs-on: ${{ matrix.os }}
timeout-minutes: 60
services:
# https://docs.github.com/en/free-pro-team@latest/actions/guides/creating-redis-service-containers
redis:
image: redis
ports:
- 6379:6379
options: >-
--health-cmd "redis-cli ping"
--health-interval 10s
--health-timeout 5s
--health-retries 5
steps:
- uses: actions/checkout@v3
- name: Prepare compiler
uses: dlang-community/setup-dlang@v1
with:
compiler: ${{ matrix.dc }}
dub: 1.29.0
- name: '[POSIX] Run tests'
env:
VIBED_DRIVER: vibe-core
PARTS: ${{ matrix.parts }}
OS: ${{ matrix.os }}
shell: bash
run: |
./run-ci.sh
- name: '[DMD] Upload coverage to Codecov'
if: matrix.dc == 'dmd-latest'
uses: codecov/codecov-action@v1
main_win:
name: Run Windows
strategy:
fail-fast: false
matrix:
os:
- windows-latest
dc:
- dmd-latest
- dmd-2.097.1
- dmd-2.096.1
- dmd-2.093.1
- dmd-2.091.1
- ldc-latest
- ldc-1.27.1
- ldc-1.26.0
- ldc-1.23.0
- ldc-1.21.0
parts:
- 'builds,unittests,examples,tests'
extra_dflags:
- ''
runs-on: ${{ matrix.os }}
timeout-minutes: 60
steps:
- uses: actions/checkout@v3
- name: Prepare compiler
uses: dlang-community/setup-dlang@v1
with:
compiler: ${{ matrix.dc }}
dub: 1.29.0
- name: '[WINDOWS] Run tests'
env:
VIBED_DRIVER: vibe-core
PARTS: ${{ matrix.parts }}
OS: ${{ matrix.os }}
shell: bash
run: |
./run-ci.sh