Blob Blame History Raw
From 4ad635e3e82b0eafac20af2de7125650796c346f Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Zbigniew=20J=C4=99drzejewski-Szmek?= <zbyszek@in.waw.pl>
Date: Thu, 5 Jul 2018 12:41:40 +0200
Subject: [PATCH] test: split calls to to_source() into seperate lines

This makes it easier to see in the traceback if it the original node
or rebuilt_node caused a failure.
---
 tests/tools.py | 4 +++-
 1 file changed, 3 insertions(+), 1 deletion(-)

diff --git a/tests/tools.py b/tests/tools.py
index b8db8fa9ae..7814c66175 100644
--- a/tests/tools.py
+++ b/tests/tools.py
@@ -125,7 +125,9 @@ class MarkChecker(object):
       rebuilt_node = parse_snippet(text, is_expr=util.is_expr(node), is_module=util.is_module(node))
 
       # Now we need to check if the two nodes are equivalent.
-      test_case.assertEqual(to_source(rebuilt_node), to_source(node))
+      left = to_source(rebuilt_node)
+      right = to_source(node)
+      test_case.assertEqual(left, right)
       tested_nodes += 1
 
     return tested_nodes