-
Notifications
You must be signed in to change notification settings - Fork 1
87 lines (69 loc) · 2.05 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
81
82
83
84
85
86
87
name: Test
on:
pull_request:
branches:
- main
push:
branches:
- main
jobs:
build:
strategy:
fail-fast: false
matrix:
os: [ ubuntu-latest ]
# All supported Perl versions except latest.
perl: [
'5.32', '5.34', '5.36',
]
# Variants of the latest Perl.
include:
# FIXME: What packages are required on Mac OS?
# - os: macos-latest
# perl: '5.38'
# FIXME: Windows tests started failing around the time we
# moved to lvalue setters. Why?
# - os: windows-latest
# perl: '5.38'
# This is effectively our normal one: all features and cover.
- name: ' (all)'
os: ubuntu-latest
perl: '5.38'
cover: true
- name: ' (no dependencies)'
os: ubuntu-latest
perl: '5.38'
plain: true
runs-on: ${{ matrix.os }}
name: v${{ matrix.perl }} on ${{ matrix.os }}${{ matrix.name }}
steps:
- uses: actions/checkout@v2
- uses: shogo82148/actions-setup-perl@v1
with:
perl-version: ${{ matrix.perl }}
- if: ${{ !matrix.plain }}
uses: ConorMacBride/install-package@v1
with:
apt: g++ cmake libprotobuf-dev libprotoc-dev
- name: Show diagnostics
run: |
perl -v
cpanm --showdeps .
# FIXME: Install the API and SDK from the repository for now,
# until it is on CPAN
- name: Install dependencies
run: |
cpanm -n https://github.com/jjatria/perl-opentelemetry.git
cpanm -n https://github.com/jjatria/perl-opentelemetry-sdk.git
cpanm --installdeps -n .
- if: ${{ matrix.cover }}
run: cpanm -n Devel::Cover::Report::Coveralls
- name: Build
run: |
perl Makefile.PL
- if: ${{ matrix.cover }}
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
run: cover -report Coveralls -test
- if: ${{ !matrix.cover }}
run: make test