From 131947dc74ad73922c9a593c48367cc0e0325df2 Mon Sep 17 00:00:00 2001 From: Noel Eck Date: Wed, 5 Oct 2016 11:54:21 -0700 Subject: [PATCH] check_pythonload: Updated assert print. Print out failing files in order in a python3-friendly way. Signed-off-by: Noel Eck --- tests/check_pythonload.py | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/tests/check_pythonload.py b/tests/check_pythonload.py index 5daa9118..8f78ea9a 100755 --- a/tests/check_pythonload.py +++ b/tests/check_pythonload.py @@ -56,9 +56,11 @@ class loadModule(unittest.TestCase): except Exception as x: failures[pyfile] = x + skeys = list(failures.keys()) + skeys.sort() self.assertEqual(len(failures), 0, '\n\nFailed to load %d modules:\n' % len(failures) + - '\n'.join(['%s: %s' % (k, ', '.join(failures[k])) for k in failures.keys()])) + '\n'.join(['%s: %s' % (k, failures[k]) for k in skeys])) if __name__ == '__main__': # Allow passing from argv