15
0

Accepting request 1136618 from home:bnavigator:branches:devel:languages:python

- Remove coverage check
- Fix zsh test failures: avoid coloring terminal

OBS-URL: https://build.opensuse.org/request/show/1136618
OBS-URL: https://build.opensuse.org/package/show/devel:languages:python/python-argcomplete?expand=0&rev=66
This commit is contained in:
2024-01-03 17:37:55 +00:00
committed by Git OBS Bridge
parent b93be79fd9
commit d7438f4aef
2 changed files with 12 additions and 6 deletions

View File

@@ -1,3 +1,9 @@
-------------------------------------------------------------------
Wed Jan 3 10:54:17 UTC 2024 - Ben Greiner <code@bnavigator.de>
- Remove coverage check
- Fix zsh test failures: avoid coloring terminal
-------------------------------------------------------------------
Fri Dec 29 18:27:06 UTC 2023 - Dirk Müller <dmueller@suse.com>

View File

@@ -1,7 +1,7 @@
#
# spec file for package python-argcomplete
#
# Copyright (c) 2023 SUSE LLC
# Copyright (c) 2024 SUSE LLC
# Copyright (c) 2013 Darin Perusich.
#
# All modifications and additions to the file contributed by third parties
@@ -28,9 +28,10 @@ URL: https://github.com/kislyuk/argcomplete
Source: https://files.pythonhosted.org/packages/source/a/argcomplete/argcomplete-%{version}.tar.gz
# Use correct place for auxiliary bashrc.sh file from pexpect
Patch3: bash-repl.patch
BuildRequires: %{python_module coverage}
BuildRequires: %{python_module base >= 3.8}
BuildRequires: %{python_module pexpect}
BuildRequires: %{python_module pip}
BuildRequires: %{python_module setuptools >= 67.2}
BuildRequires: %{python_module setuptools_scm >= 6.2}
BuildRequires: %{python_module wheel}
BuildRequires: ca-certificates
@@ -66,19 +67,18 @@ resources over the network).
%pyproject_install
%python_clone -a %{buildroot}%{_bindir}/register-python-argcomplete
%python_clone -a %{buildroot}%{_bindir}/python-argcomplete-check-easy-install-script
rm -rf %{buildroot}%{python_sitelib}/test
rm %{buildroot}%{_bindir}/activate-global-python-argcomplete
%python_expand %fdupes %{buildroot}%{$python_sitelib}
%check
export LANG=en_US.UTF-8
export TERM=xterm-mono
%{python_expand \
# https://github.com/kislyuk/argcomplete/issues/255
# https://github.com/kislyuk/argcomplete/issues/256
# https://github.com/kislyuk/argcomplete/issues/299
sed -i -e "1s|#!.*python.*|#!%{_bindir}/$python|" test/prog scripts/*
sed -i -e "1s|#!.*python.*|#!%{__$python}|" test/prog test/*.py scripts/*
sed -i -e "s|python3 |$python |g" test/test.py
PYTHONPATH=%{buildroot}%{$python_sitelib} $python -m coverage run --source=argcomplete --omit=argcomplete/packages/_shlex.py ./test/test.py -v
PYTHONPATH=%{buildroot}%{$python_sitelib} $python ./test/test.py -v
}
%post