run-tests.py: fix diff output when test-foo.out doesn't exist.
authorAlexis S. L. Carvalho <alexis@cecm.usp.br>
Fri, 21 Jul 2006 01:51:17 -0300
changeset 2703 d32b31e88391
parent 2702 133811a7688b
child 2704 99e7cf6bd2f7
run-tests.py: fix diff output when test-foo.out doesn't exist. Previously, if test-foo.out doesn't exist and test-foo outputs something, the first line of the diff will look like this: -+changeset: 0:0acdaf898367 (note the leading "-")
tests/run-tests.py
--- a/tests/run-tests.py
+++ b/tests/run-tests.py
@@ -244,7 +244,7 @@ def run_one(test):
         ref_out = splitnewlines(f.read())
         f.close()
     else:
-        ref_out = ['']
+        ref_out = []
     if out != ref_out:
         diffret = 1
         print "\nERROR: %s output changed" % (test)