From: Zsolt Dollenstein Date: Fri, 8 May 2020 15:12:52 +0000 (+0100) Subject: Improve error messages from BlackRunner X-Git-Url: https://git.madduck.net/etc/vim.git/commitdiff_plain/6ea76e9b4f42e538540baa236875c94c9dc07697?ds=sidebyside Improve error messages from BlackRunner --- diff --git a/tests/test_black.py b/tests/test_black.py index 8fafabd..baa44ab 100644 --- a/tests/test_black.py +++ b/tests/test_black.py @@ -162,7 +162,12 @@ class BlackTestCase(unittest.TestCase): self.assertEqual( result.exit_code, exit_code, - msg=f"Failed with args: {args}. Stderr: {runner.stderr_bytes.decode()!r}", + msg=( + f"Failed with args: {args}\n" + f"stdout: {runner.stdout_bytes.decode()!r}\n" + f"stderr: {runner.stderr_bytes.decode()!r}\n" + f"exception: {result.exception}" + ), ) @patch("black.dump_to_file", dump_to_stderr)