tests.yml: Add package caching.

Signed-off-by: Chris PeBenito <chpebeni@linux.microsoft.com>
This commit is contained in:
Chris PeBenito 2023-04-18 11:52:44 -04:00
parent 3b0c2095dc
commit d67d7071e4
2 changed files with 14 additions and 2 deletions

View File

@ -62,7 +62,15 @@ jobs:
sudo python -m pip install -U \
tox
- name: Build toolchain
- name: Cache SELinux userspace
uses: actions/cache@v3
id: cache-userspace
with:
path: ${{ env.USERSPACE_SRC }}
key: ${{ runner.os }}-selinux-userspace-${{ env.SELINUX_USERSPACE_VERSION }}
- name: Build SELinux userspace
if: ${{ steps.cache-userspace.outputs.cache-hit != 'true' }}
run: |
# Download current SELinux userspace tools and libraries
git clone https://github.com/SELinuxProject/selinux.git ${USERSPACE_SRC} -b ${SELINUX_USERSPACE_VERSION}

View File

@ -165,5 +165,9 @@ setup(name='setools',
# setup also requires libsepol and libselinux
# C libraries and headers to compile.
setup_requires=['setuptools', 'Cython>=0.27'],
install_requires=['setuptools', 'networkx>=2.0']
install_requires=['setuptools'],
extras_require={
"analysis": "networkx>=2.0",
"test": "tox"
}
)