From f43fa8bcb82cff19ca6e044cd2c460a31f86a5c0 Mon Sep 17 00:00:00 2001 From: Lars Wirzenius Date: Thu, 18 Feb 2021 11:04:06 +0200 Subject: test: if output is not match, print diff This makes it easier to debug failure in CI. --- subplot/summain.py | 3 +++ 1 file changed, 3 insertions(+) diff --git a/subplot/summain.py b/subplot/summain.py index ca7c0f6..d01e441 100644 --- a/subplot/summain.py +++ b/subplot/summain.py @@ -66,4 +66,7 @@ def output_matches_file(ctx, filename=None): logging.debug(f" actual:\n{actual}") logging.debug(f" expect:\n{expected}") logging.debug(f" diff:\n{diff}") + if actual != expected: + print("ERROR: diff:") + print(diff) assert_eq(actual, expected) -- cgit v1.2.1