equal
deleted
inserted
replaced
879 if options.verbose: |
879 if options.verbose: |
880 log("\nSkipping %s: %s" % (testpath, msg)) |
880 log("\nSkipping %s: %s" % (testpath, msg)) |
881 return 's', test, msg |
881 return 's', test, msg |
882 |
882 |
883 def fail(msg, ret): |
883 def fail(msg, ret): |
|
884 warned = ret is False |
884 if not options.nodiff: |
885 if not options.nodiff: |
885 log("\nERROR: %s %s" % (testpath, msg)) |
886 log("\n%s: %s %s" % (warned and 'Warning' or 'ERROR', test, msg)) |
886 if (not ret and options.interactive |
887 if (not ret and options.interactive |
887 and os.path.exists(testpath + ".err")): |
888 and os.path.exists(testpath + ".err")): |
888 iolock.acquire() |
889 iolock.acquire() |
889 print "Accept this change? [n] ", |
890 print "Accept this change? [n] ", |
890 answer = sys.stdin.readline().strip() |
891 answer = sys.stdin.readline().strip() |
893 if test.endswith(".t"): |
894 if test.endswith(".t"): |
894 rename(testpath + ".err", testpath) |
895 rename(testpath + ".err", testpath) |
895 else: |
896 else: |
896 rename(testpath + ".err", testpath + ".out") |
897 rename(testpath + ".err", testpath + ".out") |
897 return '.', test, '' |
898 return '.', test, '' |
898 return '!', test, msg |
899 return warned and '~' or '!', test, msg |
899 |
900 |
900 def success(): |
901 def success(): |
901 return '.', test, '' |
902 return '.', test, '' |
902 |
903 |
903 def ignore(msg): |
904 def ignore(msg): |