]> granicus.if.org Git - python/commitdiff
test_pep277: format function argument with ascii() on failure
authorVictor Stinner <victor.stinner@haypocalc.com>
Thu, 28 Oct 2010 11:09:09 +0000 (11:09 +0000)
committerVictor Stinner <victor.stinner@haypocalc.com>
Thu, 28 Oct 2010 11:09:09 +0000 (11:09 +0000)
"%a" instead of "%r"

Lib/test/test_pep277.py

index a7e2f007f39bd53d241108ee0da8072eb3d9d0b3..eff7ba493f2845637cf97283186a47c424836013 100644 (file)
@@ -98,7 +98,7 @@ class UnicodeFileTests(unittest.TestCase):
         if isinstance(exc_filename, bytes):
             filename = filename.encode(sys.getfilesystemencoding())
         if check_fn_in_exception:
-            self.assertEqual(exc_filename, filename, "Function '%s(%r) failed "
+            self.assertEqual(exc_filename, filename, "Function '%s(%a) failed "
                              "with bad filename in the exception: %r" %
                              (fn.__name__, filename, exc_filename))