-
Notifications
You must be signed in to change notification settings - Fork 14
83 lines (73 loc) · 2.25 KB
/
Copy pathansible-test.yml
File metadata and controls
83 lines (73 loc) · 2.25 KB
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
name: CI
on:
# Run CI against all pushes (direct commits, also merged PRs), Pull Requests
push:
branches:
- main
- dev
pull_request:
# Run CI once per day (at 06:00 UTC)
# This ensures that even if there haven't been commits that we are still testing against latest version of ansible-test for each ansible-base version
schedule:
- cron: '0 6 * * *'
workflow_dispatch:
env:
NAMESPACE: community
COLLECTION_NAME: sap_libs
jobs:
sanity:
name: Sanity (Ⓐ${{ matrix.ansible }})
strategy:
matrix:
ansible:
- stable-2.15
- stable-2.16
- stable-2.17
- stable-2.18
- stable-2.19
- devel
runs-on: >-
${{ contains(fromJson(
'["stable-2.13", "stable-2.14"]'
), matrix.ansible) && 'ubuntu-20.04' || 'ubuntu-latest' }}
steps:
- name: Check out code
uses: actions/checkout@v4
- name: Perform sanity testing
uses: ansible-community/ansible-test-gh-action@release/v1
with:
ansible-core-version: ${{ matrix.ansible }}
testing-type: sanity
units:
runs-on: >-
${{ contains(fromJson(
'["stable-2.13", "stable-2.14"]'
), matrix.ansible) && 'ubuntu-20.04' || 'ubuntu-latest' }}
name: Units (Ⓐ${{ matrix.ansible }}+py${{ matrix.python }})
strategy:
# As soon as the first unit test fails, cancel the others to free up the CI queue
fail-fast: true
matrix:
include:
- ansible: stable-2.15
python: '3.11'
- ansible: stable-2.16
python: '3.11'
- ansible: stable-2.17
python: '3.12'
- ansible: stable-2.18
python: '3.12'
- ansible: stable-2.19
python: '3.13'
- ansible: devel
python: '3.13'
steps:
- name: Check out code
uses: actions/checkout@v4
- name: Perform unit testing
uses: ansible-community/ansible-test-gh-action@release/v1
with:
ansible-core-version: ${{ matrix.ansible }}
target-python-version: ${{ matrix.python }}
testing-type: units
# Please consult the Readme for information on why we disabled integration tests temporarily.