diff options
author | CoprDistGit <infra@openeuler.org> | 2023-03-24 10:42:53 +0000 |
---|---|---|
committer | CoprDistGit <infra@openeuler.org> | 2023-03-24 10:42:53 +0000 |
commit | 4b5b6f38ef32b2d8d2ed8cb12c25f0d154fe3de6 (patch) | |
tree | 75e9e127897b4b666c48ab7c179cde04a9e04f35 | |
parent | 3f3d4bf7d50501597090a5539adb80ad6f211223 (diff) |
automatic import of rpkg
-rw-r--r-- | rpkg.spec | 18 |
1 files changed, 10 insertions, 8 deletions
@@ -12,6 +12,7 @@ Source0: https://pagure.io/releases/rpkg/%{name}-%{version}.tar.gz %global with_python2 0 # Enable python3 build by default %global with_python3 1 +%global with_check 0 # This is intended for Python 3 only, hence also no Python version in the name. %global __pytest /usr/bin/pytest%(test %{python3_pkgversion} == 3 || echo -%{python3_version}) @@ -219,15 +220,16 @@ example_cli_dir=$RPM_BUILD_ROOT%{_datadir}/%{name}/examples/cli %{__install} -p -m 0644 etc/rpkg/rpkg.conf ${example_cli_dir}%{_sysconfdir}/rpkg # need to run check as non-root -#%check -#%if 0%{?with_python2} -#%{__python2} -m nose tests -#%endif - -#%if 0%{?with_python3} -#%pytest -#%endif +%check +%if 0%{?with_check} +%if 0%{?with_python2} +%{__python2} -m nose tests +%endif +%if 0%{?with_python3} +%pytest +%endif +%endif %if 0%{?with_python2} %files -n python2-%{name} |