aboutsummaryrefslogtreecommitdiffstats
path: root/testing/py3-parameterized
diff options
context:
space:
mode:
authorNatanael Copa <ncopa@alpinelinux.org>2019-11-05 11:56:40 +0000
committerNatanael Copa <ncopa@alpinelinux.org>2019-11-05 15:35:40 +0000
commit9c664d140b6542e4b50622f61f78381d4ddd7a02 (patch)
tree46fd3df74a82162338c75a478e26dd58ed45492d /testing/py3-parameterized
parentc5f8982a543127c6bf282d9846c498b1ef2c7752 (diff)
downloadaports-9c664d140b6542e4b50622f61f78381d4ddd7a02.tar.bz2
aports-9c664d140b6542e4b50622f61f78381d4ddd7a02.tar.xz
testing/py3-parameterized: rebuild against python 3.8
Diffstat (limited to 'testing/py3-parameterized')
-rw-r--r--testing/py3-parameterized/APKBUILD9
-rw-r--r--testing/py3-parameterized/tests-Update-unittest-local-variable-name-for-Python-3.8.patch23
2 files changed, 29 insertions, 3 deletions
diff --git a/testing/py3-parameterized/APKBUILD b/testing/py3-parameterized/APKBUILD
index e72a7da935..913c127eda 100644
--- a/testing/py3-parameterized/APKBUILD
+++ b/testing/py3-parameterized/APKBUILD
@@ -3,7 +3,7 @@
pkgname=py3-parameterized
_pkgname=parameterized
pkgver=0.7.0
-pkgrel=2
+pkgrel=3
pkgdesc="Parameterized testing with any Python test framework"
url="https://github.com/wolever/parameterized"
arch="noarch"
@@ -11,7 +11,9 @@ license="BSD-2-Clause"
depends="python3"
makedepends="py3-setuptools"
checkdepends="py3-nose py3-mock py3-pytest"
-source="https://files.pythonhosted.org/packages/source/p/parameterized/parameterized-$pkgver.tar.gz"
+source="https://files.pythonhosted.org/packages/source/p/parameterized/parameterized-$pkgver.tar.gz
+ tests-Update-unittest-local-variable-name-for-Python-3.8.patch
+ "
builddir="$srcdir/"$_pkgname-$pkgver
replaces="py-parameterized" # Backwards compatibility
@@ -31,4 +33,5 @@ package() {
python3 setup.py install --prefix=/usr --root="$pkgdir"
}
-sha512sums="b76e18a7eee62fcab4385fd5d053253c096d4c3fc3a6300e8539afc4d8decc995e533085297c52f8a26411d2591a326033a740cc30a250d510aa1c11ee904246 parameterized-0.7.0.tar.gz"
+sha512sums="b76e18a7eee62fcab4385fd5d053253c096d4c3fc3a6300e8539afc4d8decc995e533085297c52f8a26411d2591a326033a740cc30a250d510aa1c11ee904246 parameterized-0.7.0.tar.gz
+39adc05e17cfe82257539d7ec9ba110d1e777a05ed9beb12215fffe03f108231ec5a3bd8996042b8821e7e2de9311fa783d1c0294c74109498942a9721ee462a tests-Update-unittest-local-variable-name-for-Python-3.8.patch"
diff --git a/testing/py3-parameterized/tests-Update-unittest-local-variable-name-for-Python-3.8.patch b/testing/py3-parameterized/tests-Update-unittest-local-variable-name-for-Python-3.8.patch
new file mode 100644
index 0000000000..c41c072071
--- /dev/null
+++ b/testing/py3-parameterized/tests-Update-unittest-local-variable-name-for-Python-3.8.patch
@@ -0,0 +1,23 @@
+From 1842e2038ae123e16601e083a553fe931f34fbd0 Mon Sep 17 00:00:00 2001
+From: Petr Viktorin <encukou@gmail.com>
+Date: Fri, 21 Jun 2019 15:36:25 +0200
+Subject: [PATCH] tests: Update unittest local variable name for Python 3.8
+
+---
+ parameterized/test.py | 3 ++-
+ 1 file changed, 2 insertions(+), 1 deletion(-)
+
+diff --git a/parameterized/test.py b/parameterized/test.py
+index 5e506f5..6b8e4d2 100644
+--- a/parameterized/test.py
++++ b/parameterized/test.py
+@@ -252,7 +252,8 @@ def _assert_docstring(self, expected_docstring, rstrip=False):
+ f_locals = stack[3][0].f_locals
+ test_method = (
+ f_locals.get("testMethod") or # Py27
+- f_locals.get("function") # Py33
++ f_locals.get("function") or # Py33
++ f_locals.get("method") # Py38
+ )
+ if test_method is None:
+ raise AssertionError("uh oh, unittest changed a local variable name")