Gentoo Archives: gentoo-commits

From: "Michał Górny" <mgorny@g.o>
To: gentoo-commits@l.g.o
Subject: [gentoo-commits] repo/gentoo:master commit in: dev-python/blinker/files/, dev-python/blinker/
Date: Thu, 12 May 2022 20:31:06
Message-Id: 1652386581.a90a4b7a4f1f7bb819250a20bcea5039fbd02062.mgorny@gentoo
1 commit: a90a4b7a4f1f7bb819250a20bcea5039fbd02062
2 Author: Michał Górny <mgorny <AT> gentoo <DOT> org>
3 AuthorDate: Thu May 12 20:16:21 2022 +0000
4 Commit: Michał Górny <mgorny <AT> gentoo <DOT> org>
5 CommitDate: Thu May 12 20:16:21 2022 +0000
6 URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=a90a4b7a
7
8 dev-python/blinker: EAPI 8, PEP517
9
10 Signed-off-by: Michał Górny <mgorny <AT> gentoo.org>
11
12 dev-python/blinker/blinker-1.4-r3.ebuild | 34 +++++++++++++++++++++++
13 dev-python/blinker/files/blinker-1.4-pytest.patch | 31 +++++++++++++++++++++
14 2 files changed, 65 insertions(+)
15
16 diff --git a/dev-python/blinker/blinker-1.4-r3.ebuild b/dev-python/blinker/blinker-1.4-r3.ebuild
17 new file mode 100644
18 index 000000000000..e5dccf211b16
19 --- /dev/null
20 +++ b/dev-python/blinker/blinker-1.4-r3.ebuild
21 @@ -0,0 +1,34 @@
22 +# Copyright 1999-2022 Gentoo Authors
23 +# Distributed under the terms of the GNU General Public License v2
24 +
25 +EAPI=8
26 +
27 +DISTUTILS_USE_PEP517=setuptools
28 +PYTHON_COMPAT=( python3_{8..10} pypy3 )
29 +
30 +inherit distutils-r1
31 +
32 +DESCRIPTION="Fast, simple object-to-object and broadcast signaling"
33 +HOMEPAGE="
34 + https://pythonhosted.org/blinker/
35 + https://github.com/pallets-eco/blinker/
36 + https://pypi.org/project/blinker/
37 +"
38 +SRC_URI="mirror://pypi/${PN:0:1}/${PN}/${P}.tar.gz"
39 +
40 +LICENSE="MIT"
41 +SLOT="0"
42 +KEYWORDS="~alpha ~amd64 ~arm ~arm64 ~hppa ~ia64 ~loong ~mips ~ppc ~ppc64 ~riscv ~s390 ~sparc ~x86 ~amd64-linux ~x86-linux ~x64-macos"
43 +IUSE="doc"
44 +
45 +distutils_enable_tests pytest
46 +
47 +PATCHES=(
48 + # https://github.com/pallets-eco/blinker/pull/60
49 + "${FILESDIR}"/${P}-pytest.patch
50 +)
51 +
52 +python_install_all() {
53 + use doc && HTML_DOCS=( docs/html/. )
54 + distutils-r1_python_install_all
55 +}
56
57 diff --git a/dev-python/blinker/files/blinker-1.4-pytest.patch b/dev-python/blinker/files/blinker-1.4-pytest.patch
58 new file mode 100644
59 index 000000000000..e5c2b04998b5
60 --- /dev/null
61 +++ b/dev-python/blinker/files/blinker-1.4-pytest.patch
62 @@ -0,0 +1,31 @@
63 +From 8238e16c699ce7f99f5ff3f80d03d332d72015f8 Mon Sep 17 00:00:00 2001
64 +From: pgajdos <pgajdos@××××.cz>
65 +Date: Wed, 8 Jul 2020 15:22:19 +0200
66 +Subject: [PATCH] use pytest instead of deprecated nose
67 +
68 +---
69 + tests/test_signals.py | 4 ++--
70 + 1 file changed, 2 insertions(+), 2 deletions(-)
71 +
72 +diff --git a/tests/test_signals.py b/tests/test_signals.py
73 +index 2d6a65a..e74db47 100644
74 +--- a/tests/test_signals.py
75 ++++ b/tests/test_signals.py
76 +@@ -4,7 +4,7 @@
77 +
78 + import blinker
79 +
80 +-from nose.tools import assert_raises
81 ++import pytest
82 +
83 +
84 + jython = sys.platform.startswith('java')
85 +@@ -227,7 +227,7 @@ def receiver(sender, **kw):
86 + pass
87 + sig = blinker.Signal()
88 +
89 +- assert_raises(TypeError, sig.connect, receiver)
90 ++ pytest.raises(TypeError, sig.connect, receiver)
91 + assert not sig.receivers
92 + assert not sig._by_receiver
93 + assert sig._by_sender == {blinker.base.ANY_ID: set()}