https://github.com/testing-cabal/testtools/commit/29004731f9c480b7c44a9c2605513d50d372898f.patch Should be fixed in the next release From 29004731f9c480b7c44a9c2605513d50d372898f Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Miro=20Hron=C4=8Dok?= 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 --- .travis.yml | 1 + testtools/tests/matchers/test_exception.py | 11 +++++++++-- 2 files changed, 10 insertions(+), 2 deletions(-) diff --git a/.travis.yml b/.travis.yml index 7f1f4db7..784608e0 100644 --- a/.travis.yml +++ b/.travis.yml @@ -5,6 +5,7 @@ python: - "3.4" - "3.5" - "3.6" + - "3.7-dev" - "pypy" install: 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"))), ] >
path: root/config-daemon.ac
AgeCommit message (Expand)Author
2021-11-16daemon: Do not deduplicate files smaller than 8 KiB....Ludovic Courtès
2021-06-18Start enabling substitutes from bordeaux.guix.gnu.org....Christopher Baines
2020-12-11maint: Remove unused 'NIX_VERSION' macro....Ludovic Courtès
2020-12-11maint: Avoid macros obsolete in Autoconf 2.70....Ludovic Courtès
2019-11-27daemon: GC remove-unused-links phase uses 'statx' when available....Ludovic Courtès
2019-11-13daemon: Don't include <linux/fs.h>....Ludovic Courtès
2019-09-08daemon: Run 'guix substitute' directly and assume a single substituter....Ludovic Courtès
2019-09-08daemon: Run 'guix offload' directly....Ludovic Courtès
2019-09-08daemon: Run 'guix perform-download' directly....Ludovic Courtès
2019-09-08daemon: Run 'guix authenticate' directly....Ludovic Courtès
2019-09-08daemon: Invoke 'guix gc --list-busy' instead of 'list-runtime-roots'....Ludovic Courtès
2019-05-01build: Change default substitute server to "ci.guix.gnu.org"....Ludovic Courtès