15
0
forked from pool/python-ftfy

Accepting request 809375 from devel:languages:python

OBS-URL: https://build.opensuse.org/request/show/809375
OBS-URL: https://build.opensuse.org/package/show/openSUSE:Factory/python-ftfy?expand=0&rev=6
This commit is contained in:
2020-05-28 07:17:03 +00:00
committed by Git OBS Bridge
2 changed files with 17 additions and 2 deletions

View File

@@ -1,3 +1,8 @@
-------------------------------------------------------------------
Tue May 26 06:34:21 UTC 2020 - Petr Gajdos <pgajdos@suse.com>
- %python3_only -> %python_alternative
-------------------------------------------------------------------
Tue Mar 10 08:48:18 UTC 2020 - Tomáš Chvátal <tchvatal@suse.com>

View File

@@ -29,6 +29,8 @@ BuildRequires: %{python_module setuptools}
BuildRequires: fdupes
BuildRequires: python-rpm-macros
Requires: python-wcwidth
Requires(post): update-alternatives
Requires(postun): update-alternatives
BuildArch: noarch
# SECTION test requirements
BuildRequires: %{python_module pytest}
@@ -48,16 +50,24 @@ put through an encode/decode cycle with different encodings.
%install
%python_install
%python_clone -a %{buildroot}%{_bindir}/ftfy
%python_expand %fdupes %{buildroot}%{$python_sitelib}
%check
export PATH="$PATH:%{buildroot}%{_bindir}"
%pytest
# test_cli: ftfy binary not found (update-alternatives)
%pytest -k 'not test_cli'
%post
%python_install_alternative ftfy
%postun
%python_uninstall_alternative ftfy
%files %{python_files}
%doc CHANGELOG.md README.md
%license LICENSE.txt
%python3_only %{_bindir}/ftfy
%python_alternative %{_bindir}/ftfy
%{python_sitelib}/*
%changelog