tests: Enable the pykickstart unit tests

These now work fine in a mock environment and provide excellent
coverage.

Related: RHEL-61432
This commit is contained in:
Brian C. Lane 2023-02-21 10:55:24 -08:00
parent 4618e10198
commit f0a64856c3
2 changed files with 4 additions and 18 deletions

View File

@ -1,7 +1,6 @@
# Disable tests by default because they fail to run inside mock builds
# at the moment, but can run locally. To build and run tests, do:
# rpmbuild -ba --with runtests pykickstart.spec
%bcond_with runtests
# Enable tests by default. To disable them use:
# rpmbuild -ba --without runtests pykickstart.spec
%bcond_without runtests
Name: pykickstart
Version: 3.32.12
@ -26,7 +25,6 @@ BuildRequires: make
# Only required when building with runtests
%if %{with runtests}
BuildRequires: python3-coverage
BuildRequires: python3-sphinx
%endif
@ -55,7 +53,7 @@ make PYTHON=%{__python3} DESTDIR=%{buildroot} install
%check
%if %{with runtests}
make PYTHON=%{__python3} test
LC_ALL=C make PYTHON=%{__python3} test-no-coverage
%endif
%files

View File

@ -1,12 +0,0 @@
---
- hosts: localhost
tags:
- classic
roles:
- role: standard-test-source
- role: standard-test-basic
required_packages:
- python3-kickstart
tests:
- simple:
run: ./run_tests.sh {{ tenv_workdir }}