Commit 9f2bba01 by Stoned Elipot

Fix diff output vertical spacing

parent a875b637
......@@ -627,8 +627,8 @@ def get_diff(before, after):
try:
with warnings.catch_warnings():
warnings.simplefilter('ignore')
differ = difflib.unified_diff(before.split("\n"), after.split("\n"), 'before', 'after', '', '', 10)
return "\n".join(list(differ))
differ = difflib.unified_diff(before.splitlines(True), after.splitlines(True), 'before', 'after', '', '', 10)
return "".join(list(differ))
except UnicodeDecodeError:
return ">> the files are different, but the diff library cannot compare unicode strings"
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment