Skip to content

Commit 0689678

Browse files
committed
cache: pip, ansible unit tests
1 parent 48ae5e8 commit 0689678

File tree

1 file changed

+19
-37
lines changed

1 file changed

+19
-37
lines changed

.github/workflows/pull-request-management.yml

Lines changed: 19 additions & 37 deletions
Original file line numberDiff line numberDiff line change
@@ -373,43 +373,25 @@ jobs:
373373
cd ansible_collections/arista/avd/
374374
ansible-test sanity --color yes -v
375375
376-
# ansible_test_units:
377-
# name: Run ansible-test units test cases
378-
# runs-on: ubuntu-latest
379-
# needs: [ file-changes ]
380-
# steps:
381-
# - uses: actions/checkout@v4
382-
# # Cache pip dependencies
383-
# - name: Cache pip dependencies
384-
# id: cache-pip
385-
# uses: actions/cache@v3
386-
# with:
387-
# path: ~/.cache/pip
388-
# key: ${{ runner.os }}-pip-${{ hashFiles('.github/requirements-ci.txt') }}
389-
# restore-keys: |
390-
# ${{ runner.os }}-pip-
391-
392-
# # Cache ansible-core dependencies
393-
# - name: Cache ansible-core dependencies
394-
# id: cache-ansible
395-
# uses: actions/cache@v3
396-
# with:
397-
# path: ~/.cache/ansible-core
398-
# key: ${{ runner.os }}-ansible-core-<2.19.0
399-
# restore-keys: |
400-
# ${{ runner.os }}-ansible-core-
401-
# - name: Set up Python 3
402-
# uses: actions/setup-python@v5
403-
# with:
404-
# python-version: |
405-
# 3.10
406-
# - name: 'Install Python requirements'
407-
# run: |
408-
# pip install mock pytest pytest-mock pytest-xdist pyyaml "ansible-core<2.19.0" -r .github/requirements-ci.txt --upgrade
409-
# - name: 'Run ansible-test units test cases'
410-
# run: |
411-
# cd ansible_collections/arista/avd/
412-
# ansible-test units -vv
376+
ansible_test_units:
377+
name: Run ansible-test units test cases
378+
runs-on: ubuntu-latest
379+
needs: [ file-changes ]
380+
steps:
381+
- uses: actions/checkout@v4
382+
- name: Set up Python 3
383+
uses: actions/setup-python@v5
384+
with:
385+
python-version: |
386+
3.10
387+
cache: 'pip'
388+
- name: 'Install Python requirements'
389+
run: |
390+
pip install mock pytest pytest-mock pytest-xdist pyyaml "ansible-core<2.19.0" -r .github/requirements-ci.txt --upgrade
391+
- name: 'Run ansible-test units test cases'
392+
run: |
393+
cd ansible_collections/arista/avd/
394+
ansible-test units -vv
413395
414396
# ansible_test_integration:
415397
# name: Run ansible-test integration test cases

0 commit comments

Comments
 (0)