-
Notifications
You must be signed in to change notification settings - Fork 0
74 lines (61 loc) · 1.61 KB
/
lint.yaml
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
---
name: "Lint testing"
on:
pull_request:
branches:
- "main"
push:
branches:
- "feature_*"
jobs:
setup_matrix:
name: "Setup Test Matrix"
runs-on: ubuntu-22.04
outputs:
matrix: ${{ steps.get-matrix.outputs.matrix }}
steps:
- name: Checkout Source
uses: actions/checkout@v3
- name: Activate Ruby 3.2
uses: ruby/setup-ruby@v1
with:
ruby-version: "3.2.3"
bundler-cache: true
- name: Print bundle environment
run: |
echo ::group::bundler environment
bundle env
echo ::endgroup::
- name: Setup Integration Test Matrix
id: get-matrix
run: |
echo "matrix=$(cat test_matrix.json | tr -s '\n' ' ')" >> $GITHUB_OUTPUT
cat $GITHUB_OUTPUT
lint:
name: "Lint tests (${{matrix.collection.agent_version}})"
needs:
- setup_matrix
if: ${{ needs.setup_matrix.outputs.matrix != '{}' }}
runs-on: ubuntu-22.04
strategy:
fail-fast: false
matrix: ${{fromJson(needs.setup_matrix.outputs.matrix)}}
env:
PUPPET_GEM_VERSION: ${{matrix.collection.gem_version}}
FACTER_GEM_VERSION: 'https://github.com/puppetlabs/facter#main' # why is this set?
steps:
- name: Checkout Source
uses: actions/checkout@v3
- name: Activate Ruby 3.2
uses: ruby/setup-ruby@v1
with:
ruby-version: "3.2.3"
bundler-cache: true
- name: Print bundle environment
run: |
echo ::group::bundler environment
bundle env
echo ::endgroup::
- name: "Run tests"
run: |
bundle exec rake validate