← Back to team overview

testtools-dev team mailing list archive

Re: [Merge] lp:~gz/testtools/raises_regressions_675327 into lp:testtools

 

So, a change like the following gets us back to what's currently on trunk. Want me to commit it?

=== modified file 'testtools/matchers.py'
--- testtools/matchers.py       2010-11-19 18:11:39 +0000
+++ testtools/matchers.py       2010-11-22 08:44:19 +0000
@@ -363,7 +363,7 @@
     def __str__(self):
         if self._is_instance:
             return "MatchesException(%s)" % _error_repr(self.expected)
-        return "MatchesException(%s)" % self.expected.__name__
+        return "MatchesException(%s)" % repr(self.expected)


 class StartsWith(Matcher):

=== modified file 'testtools/tests/test_matchers.py'
--- testtools/tests/test_matchers.py    2010-11-19 18:11:39 +0000
+++ testtools/tests/test_matchers.py    2010-11-22 08:43:20 +0000
@@ -200,7 +200,7 @@
     matches_mismatches = [error_base_foo]

     str_examples = [
-        ("MatchesException(Exception)",
+        ("MatchesException(%r)" % Exception,
          MatchesException(Exception))
         ]
     describe_examples = [
-- 
https://code.launchpad.net/~gz/testtools/raises_regressions_675327/+merge/41342
Your team testtools developers is requested to review the proposed merge of lp:~gz/testtools/raises_regressions_675327 into lp:testtools.



References