From 978259e9b3744027304477306a13b0c32d21885c Mon Sep 17 00:00:00 2001 From: Brett Cannon Date: Thu, 2 Apr 2009 15:32:07 +0000 Subject: Give a more informative message on an importlib test upon failure. --- Lib/importlib/test/source/test_abc_loader.py | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/Lib/importlib/test/source/test_abc_loader.py b/Lib/importlib/test/source/test_abc_loader.py index 0e7408d..a237a5f 100644 --- a/Lib/importlib/test/source/test_abc_loader.py +++ b/Lib/importlib/test/source/test_abc_loader.py @@ -123,7 +123,9 @@ class PyLoaderTests(testing_abc.LoaderTests): def eq_attrs(self, ob, **kwargs): for attr, val in kwargs.items(): - self.assertEqual(getattr(ob, attr), val) + found = getattr(ob, attr) + self.assertEqual(found, val, + "{} attribute: {} != {}".format(attr, found, val)) def test_module(self): name = '' -- cgit v0.12