Release v1.5.0 #1993
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: Python CI | |
on: | |
push: | |
branches: | |
- "master" | |
- "release/*" | |
pull_request: | |
branches: | |
- "master" | |
- "release/*" | |
concurrency: | |
group: ${{ github.workflow }}-${{ github.event.pull_request.number || github.ref }} | |
cancel-in-progress: true | |
jobs: | |
ruff: | |
runs-on: ubuntu-20.04 | |
steps: | |
- uses: actions/checkout@v4 | |
- uses: chartboost/ruff-action@v1 | |
with: | |
src: fapolicy_analyzer | |
ui_test: | |
name: UI Test Suite for Python ${{ matrix.python-version }} | |
runs-on: ubuntu-20.04 | |
strategy: | |
matrix: | |
python-version: [ "3.9", "3.10", "3.11", "3.12" ] | |
steps: | |
- uses: actions/checkout@v4 | |
- name: Install requirements | |
run: | | |
sudo apt-get update | |
sudo apt-get install libgtk-3-dev | |
sudo apt-get install libgirepository1.0-dev | |
sudo apt-get install xvfb | |
sudo apt-get install libgtksourceview-3.0-dev | |
sudo apt-get install gir1.2-webkit2-4.0 | |
sudo apt-get install libdbus-1-dev libaudit-dev libauparse-dev | |
- name: Set up Python ${{ matrix.python-version }} | |
uses: actions/setup-python@v4 | |
with: | |
python-version: ${{ matrix.python-version }} | |
- name: Install Rust | |
uses: dtolnay/rust-toolchain@v1 | |
with: | |
toolchain: 1.79.0 | |
- name: Install extra locales | |
id: install_locales | |
run: | | |
sudo apt-get -y install locales | |
sudo locale-gen es_ES.UTF-8 | |
- name: Install dependencies | |
id: install_deps | |
run: | | |
python -m pip install --upgrade pip | |
pip install pipenv==2023.7.4 || pip install pipenv | |
pipenv install --dev --python ${{ matrix.python-version }} | |
echo "virt_env=$(pipenv --venv)" >> $GITHUB_OUTPUT | |
- name: Setup Bindings | |
run: pipenv run python setup.py develop | |
- name: Test with pytest | |
run: pipenv run test |