[arch-commits] Commit in python-testtools/trunk (PKGBUILD python-3.7.patch)

2020-03-14 Thread Felix Yan via arch-commits
Date: Saturday, March 14, 2020 @ 17:56:12
  Author: felixonmars
Revision: 597055

upgpkg: python-testtools 2.4.0-1

Modified:
  python-testtools/trunk/PKGBUILD
Deleted:
  python-testtools/trunk/python-3.7.patch

--+
 PKGBUILD |   12 
 python-3.7.patch |   38 --
 2 files changed, 4 insertions(+), 46 deletions(-)

Modified: PKGBUILD
===
--- PKGBUILD2020-03-14 17:54:58 UTC (rev 597054)
+++ PKGBUILD2020-03-14 17:56:12 UTC (rev 597055)
@@ -1,8 +1,8 @@
 # Maintainer: Felix Yan 
 
 pkgname=python-testtools
-pkgver=2.3.0
-pkgrel=7
+pkgver=2.4.0
+pkgrel=1
 pkgdesc="Extensions to the Python standard library unit testing framework"
 arch=('any')
 license=('MIT')
@@ -10,16 +10,12 @@
 depends=('python-pbr' 'python-extras' 'python-fixtures' 'python-pyrsistent' 
'python-mimeparse')
 makedepends=('python-setuptools')
 checkdepends=('python-testscenarios')
-source=("$pkgname-$pkgver.tar.gz::https://github.com/testing-cabal/testtools/archive/$pkgver.tar.gz";
-'python-3.7.patch')
-sha512sums=('7c3b9e180c5f22d613763446525fcb3f7f260d79bc875669134c3077af0e0d3e101863429e0469ffcb26fd0755b2c915454abc949be864639a2faa9cf5024c62'
-
'12430f9b813fea33b4e7530d446f5eebfe65785f4132b8732f771cbe72ed23bfdf3841db0a85ffab58f518bccbb5cf2711b62021b9ee294a9efc28b5df59d411')
+source=("$pkgname-$pkgver.tar.gz::https://github.com/testing-cabal/testtools/archive/$pkgver.tar.gz";)
+sha512sums=('7983cb8d4dae3bc4e37d967e09f735d0753a9f517f00e53c4884d86c56d3272bb34d56a8246c74e44cff0087a713973a9cd4aa5d86f9ec8d60e842a6db92')
 
 export PBR_VERSION=$pkgver
 
 prepare() {
-  patch -Np1 -d testtools-$pkgver 
-Date: Thu, 17 May 2018 17:52:26 +0200
-Subject: [PATCH] Fix the tests on Python 3.7
-
-Exception's repr got changed not to include trailing comma
-
-Fixes https://github.com/testing-cabal/testtools/issues/270
-
-diff --git a/testtools/tests/matchers/test_exception.py 
b/testtools/tests/matchers/test_exception.py
-index 6cd80af1..acd39252 100644
 a/testtools/tests/matchers/test_exception.py
-+++ b/testtools/tests/matchers/test_exception.py
-@@ -32,15 +32,22 @@ class TestMatchesExceptionInstanceInterface(TestCase, 
TestMatchersInterface):
- matches_matches = [error_foo]
- matches_mismatches = [error_bar, error_base_foo]
- 
-+if sys.version_info >= (3, 7):
-+# exception's repr has changed
-+_e = ''
-+else:
-+_e = ','
-+
- str_examples = [
--("MatchesException(Exception('foo',))",
-+("MatchesException(Exception('foo'%s))" % _e,
-  MatchesException(Exception('foo')))
- ]
- describe_examples = [
- ("%r is not a %r" % (Exception, ValueError),
-  error_base_foo,
-  MatchesException(ValueError("foo"))),
--("ValueError('bar',) has different arguments to ValueError('foo',).",
-+("ValueError('bar'%s) has different arguments to ValueError('foo'%s)."
-+ % (_e, _e),
-  error_bar,
-  MatchesException(ValueError("foo"))),
- ]


[arch-commits] Commit in python-testtools/trunk (PKGBUILD python-3.7.patch)

2019-10-30 Thread Evangelos Foutras via arch-commits
Date: Wednesday, October 30, 2019 @ 09:59:49
  Author: foutrelis
Revision: 520962

Fix build with Python 3.7+

Added:
  python-testtools/trunk/python-3.7.patch
Modified:
  python-testtools/trunk/PKGBUILD

--+
 PKGBUILD |8 ++--
 python-3.7.patch |   38 ++
 2 files changed, 44 insertions(+), 2 deletions(-)

Modified: PKGBUILD
===
--- PKGBUILD2019-10-30 09:21:03 UTC (rev 520961)
+++ PKGBUILD2019-10-30 09:59:49 UTC (rev 520962)
@@ -13,12 +13,16 @@
  'python-fixtures' 'python2-fixtures' 'python-mimeparse' 
'python2-mimeparse'
  'python2-unittest2' 'python2-traceback2')
 checkdepends=('python-testscenarios' 'python2-testscenarios')
-source=("$pkgbase-$pkgver.tar.gz::https://github.com/testing-cabal/testtools/archive/$pkgver.tar.gz";)
-sha512sums=('7c3b9e180c5f22d613763446525fcb3f7f260d79bc875669134c3077af0e0d3e101863429e0469ffcb26fd0755b2c915454abc949be864639a2faa9cf5024c62')
+source=("$pkgbase-$pkgver.tar.gz::https://github.com/testing-cabal/testtools/archive/$pkgver.tar.gz";
+'python-3.7.patch')
+sha512sums=('7c3b9e180c5f22d613763446525fcb3f7f260d79bc875669134c3077af0e0d3e101863429e0469ffcb26fd0755b2c915454abc949be864639a2faa9cf5024c62'
+
'12430f9b813fea33b4e7530d446f5eebfe65785f4132b8732f771cbe72ed23bfdf3841db0a85ffab58f518bccbb5cf2711b62021b9ee294a9efc28b5df59d411')
 
 prepare() {
   cp -a testtools-$pkgver{,-py2}
 
+  patch -Np1 -d testtools-$pkgver 
+Date: Thu, 17 May 2018 17:52:26 +0200
+Subject: [PATCH] Fix the tests on Python 3.7
+
+Exception's repr got changed not to include trailing comma
+
+Fixes https://github.com/testing-cabal/testtools/issues/270
+
+diff --git a/testtools/tests/matchers/test_exception.py 
b/testtools/tests/matchers/test_exception.py
+index 6cd80af1..acd39252 100644
+--- a/testtools/tests/matchers/test_exception.py
 b/testtools/tests/matchers/test_exception.py
+@@ -32,15 +32,22 @@ class TestMatchesExceptionInstanceInterface(TestCase, 
TestMatchersInterface):
+ matches_matches = [error_foo]
+ matches_mismatches = [error_bar, error_base_foo]
+ 
++if sys.version_info >= (3, 7):
++# exception's repr has changed
++_e = ''
++else:
++_e = ','
++
+ str_examples = [
+-("MatchesException(Exception('foo',))",
++("MatchesException(Exception('foo'%s))" % _e,
+  MatchesException(Exception('foo')))
+ ]
+ describe_examples = [
+ ("%r is not a %r" % (Exception, ValueError),
+  error_base_foo,
+  MatchesException(ValueError("foo"))),
+-("ValueError('bar',) has different arguments to ValueError('foo',).",
++("ValueError('bar'%s) has different arguments to ValueError('foo'%s)."
++ % (_e, _e),
+  error_bar,
+  MatchesException(ValueError("foo"))),
+ ]