Update README.md #403
Workflow file for this run
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
--- | |
name: repo-unit | |
on: | |
push: | |
pull_request: | |
jobs: | |
units: | |
name: Unit (${{ matrix.ansible }}+py${{ matrix.python }}) | |
strategy: | |
matrix: | |
include: | |
- ansible: stable-2.12 | |
python: '3.10' | |
- ansible: stable-2.13 | |
python: '3.10' | |
- ansible: stable-2.14 | |
python: '3.10' | |
- ansible: stable-2.15 | |
python: '3.10' | |
- ansible: stable-2.16 | |
python: '3.10' | |
- ansible: stable-2.17 | |
python: '3.10' | |
- ansible: devel | |
python: '3.11' | |
runs-on: ubuntu-latest | |
steps: | |
# ansible-test requires the collection to be in a directory in the form | |
# .../ansible_collections/NAMESPACE/COLLECTION_NAME/ | |
- name: Check out code | |
uses: actions/checkout@v2 | |
with: | |
path: ansible_collections/datadope/discovery | |
- name: Check out community.internal_test_tools | |
uses: actions/checkout@master | |
with: | |
repository: ansible-collections/community.internal_test_tools | |
path: ansible_collections/community/internal_test_tools | |
- name: Set up Python ${{ matrix.python }} for Ansible ${{ matrix.ansible }} | |
uses: actions/setup-python@v2 | |
with: | |
python-version: ${{ matrix.python }} | |
# Install the head of the given branch (devel, stable-2.10) | |
- name: Install ansible-base (${{ matrix.ansible }}) | |
run: pip install https://github.com/ansible/ansible/archive/${{ matrix.ansible }}.tar.gz --disable-pip-version-check | |
# run ansible-test units inside of Docker. | |
# The docker container has all the pinned dependencies that are required. | |
# Explicity specify the version of Python we want to test | |
- name: Run unit tests | |
run: ansible-test units --docker default --color --python ${{ matrix.python }} -v --requirements | |
working-directory: ./ansible_collections/datadope/discovery |