mirror of
https://github.com/virt-manager/virt-manager.git
synced 2025-01-08 21:18:04 +03:00
14c5684f25
Split the installation of the base dependencies & the RPM build dependencies in two steps, so they can be reordered as needed later on. Signed-off-by: Pino Toscano <ptoscano@redhat.com>
47 lines
1.2 KiB
YAML
47 lines
1.2 KiB
YAML
name: Test on fedora:latest
|
|
|
|
on: [push, pull_request]
|
|
|
|
jobs:
|
|
# Setup latest Fedora with latest libvirt from virt-preview, build
|
|
# the RPM, verify it installs, run test suite, upload coverage
|
|
test:
|
|
runs-on: ubuntu-latest
|
|
container:
|
|
image: fedora:latest
|
|
|
|
steps:
|
|
- uses: actions/checkout@v4
|
|
|
|
- name: Install base RPM packages
|
|
run: |
|
|
# glibc-langpacks-en needed to work around python locale issues
|
|
# git-core needed for codecov/codecov-action
|
|
dnf install -y \
|
|
git-core \
|
|
rpm-build \
|
|
dnf-plugins-core \
|
|
glibc-langpack-en \
|
|
python3-pytest python3-pytest-cov
|
|
|
|
- name: Install RPM build deps
|
|
run: |
|
|
dnf builddep -y ./virt-manager.spec
|
|
|
|
- name: Build RPM and test install
|
|
run: |
|
|
./setup.py rpm
|
|
dnf install -y \
|
|
noarch/virt-install*.rpm \
|
|
noarch/virt-manager-common*.rpm
|
|
|
|
- name: Run test suite and generate coverage report
|
|
run: |
|
|
pytest --cov --cov-report=xml
|
|
|
|
- name: Upload coverage to Codecov
|
|
uses: codecov/codecov-action@v3
|
|
with:
|
|
file: ./coverage.xml
|
|
flags: unittests
|