-
Notifications
You must be signed in to change notification settings - Fork 109
110 lines (106 loc) · 3.09 KB
/
erlang.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
---
name: Erlang
on:
pull_request:
branches:
- 'main'
push:
branches:
- 'main'
jobs:
build:
name: Test on OTP ${{ matrix.otp_version }} and ${{ matrix.os }}
runs-on: ${{ matrix.os }}
strategy:
matrix:
otp_version: ['25.0.3', '24.1.2', '23.3.4.16']
rebar3_version: ['3.19.0']
os: [ubuntu-18.04]
env:
OTP_VERSION: ${{ matrix.otp_version }}
OTEL_TRACES_EXPORTER: "none"
steps:
- uses: actions/checkout@v2
- name: Run Collector
run: docker-compose up -d
- uses: erlef/setup-beam@v1
with:
otp-version: ${{ matrix.otp_version }}
rebar3-version: ${{ matrix.rebar3_version }}
elixir-version: '1.13.4'
- uses: actions/cache@v2
name: Cache
with:
path: |
_build
key: ${{ runner.os }}-build-${{ matrix.otp_version }}-${{ hashFiles(format('rebar.lock')) }}-2
restore-keys: |
${{ runner.os }}-build-${{ matrix.otp_version }}-2-
- name: Compile
run: rebar3 compile
- name: EUnit tests
run: rebar3 eunit --cover
- name: Common Test tests
run: rebar3 ct --cover
- name: Upload Test Report
uses: actions/upload-artifact@v3
if: always() # always run even if the previous step fails
with:
name: junit-test-results
path: '**/_build/test/logs/*/junit_report.xml'
retention-days: 1
- name: XRef
run: rebar3 xref
- name: Covertool
if: ${{ always() }}
run: rebar3 covertool generate
- uses: codecov/codecov-action@v3
if: ${{ always() }}
with:
file: _build/test/covertool/opentelemetry.covertool.xml
env_vars: OTP_VERSION
flags: sdk,erlang
- uses: codecov/codecov-action@v3
if: ${{ always() }}
with:
file: _build/test/covertool/opentelemetry_api.covertool.xml
env_vars: OTP_VERSION
flags: api,erlang
- uses: codecov/codecov-action@v3
if: ${{ always() }}
with:
file: _build/test/covertool/opentelemetry_exporter.covertool.xml
env_vars: OTP_VERSION
flags: exporter,erlang
- uses: codecov/codecov-action@v3
if: ${{ always() }}
with:
file: _build/test/covertool/opentelemetry_zipkin.covertool.xml
env_vars: OTP_VERSION
flags: zipkin,erlang
dialyzer:
name: Dialyze on OTP ${{ matrix.otp_version }} and ${{ matrix.os }}
runs-on: ${{ matrix.os }}
strategy:
matrix:
otp_version: ['25.0.3']
rebar3_version: ['3.19.0']
os: [ubuntu-18.04]
steps:
- uses: actions/checkout@v2
- uses: erlef/setup-beam@v1
with:
otp-version: ${{ matrix.otp_version }}
rebar3-version: ${{ matrix.rebar3_version }}
- uses: actions/cache@v2
name: Cache
with:
path: |
_build
key: ${{ runner.os }}-build-${{ matrix.otp_version }}-${{ hashFiles('rebar.lock') }}-2
restore-keys: |
${{ runner.os }}-dialyzer-${{ matrix.otp_version }}-2-
- name: Compile
run: rebar3 compile
- name: Dialyzer
run: rebar3 dialyzer