tests/run-tests.py
branchstable
changeset 916 dd5c50a018b0
parent 915 5660a21567b7
child 918 3071ec5d085c
equal deleted inserted replaced
915:5660a21567b7 916:dd5c50a018b0
   824     elif ret == 'timeout':
   824     elif ret == 'timeout':
   825         mark = 't'
   825         mark = 't'
   826         fail("timed out", ret)
   826         fail("timed out", ret)
   827     elif out != refout:
   827     elif out != refout:
   828         mark = '!'
   828         mark = '!'
   829         if ret:
   829         if not options.nodiff:
   830             fail("output changed and returned error code %d" % ret, ret)
       
   831         else:
       
   832             fail("output changed", ret)
       
   833         if ret != 'timeout' and not options.nodiff:
       
   834             iolock.acquire()
   830             iolock.acquire()
   835             if options.view:
   831             if options.view:
   836                 os.system("%s %s %s" % (options.view, ref, err))
   832                 os.system("%s %s %s" % (options.view, ref, err))
   837             else:
   833             else:
   838                 showdiff(refout, out, ref, err)
   834                 showdiff(refout, out, ref, err)
   839             iolock.release()
   835             iolock.release()
       
   836         if ret:
       
   837             fail("output changed and returned error code %d" % ret, ret)
       
   838         else:
       
   839             fail("output changed", ret)
   840         ret = 1
   840         ret = 1
   841     elif ret:
   841     elif ret:
   842         mark = '!'
   842         mark = '!'
   843         fail("returned error code %d" % ret, ret)
   843         fail("returned error code %d" % ret, ret)
   844 
   844