tests/run-tests.py
branchstable
changeset 1235 8fd26ac1deca
parent 1234 750a0ed6f380
child 1236 b1062bc760a9
equal deleted inserted replaced
1234:750a0ed6f380 1235:8fd26ac1deca
   903                     break
   903                     break
   904                 else:
   904                 else:
   905                     ignore("doesn't match keyword")
   905                     ignore("doesn't match keyword")
   906                     return None
   906                     return None
   907 
   907 
   908     vlog("# Test", test)
       
   909 
       
   910     createhgrc(HGRCPATH, options)
       
   911 
       
   912     if os.path.exists(err):
       
   913         os.remove(err)       # Remove any previous output files
       
   914 
       
   915     for ext, func, out in testtypes:
   908     for ext, func, out in testtypes:
   916         if lctest.startswith("test-") and lctest.endswith(ext):
   909         if lctest.startswith("test-") and lctest.endswith(ext):
   917             runner = func
   910             runner = func
   918             ref = os.path.join(TESTDIR, test + out)
   911             ref = os.path.join(TESTDIR, test + out)
   919             break
   912             break
   920     else:
   913     else:
   921         return skip("unknown test type")
   914         return skip("unknown test type")
       
   915 
       
   916     vlog("# Test", test)
       
   917 
       
   918     createhgrc(HGRCPATH, options)
       
   919 
       
   920     if os.path.exists(err):
       
   921         os.remove(err)       # Remove any previous output files
   922 
   922 
   923     # Make a tmp subdirectory to work in
   923     # Make a tmp subdirectory to work in
   924     testtmp = os.environ["TESTTMP"] = os.environ["HOME"] = \
   924     testtmp = os.environ["TESTTMP"] = os.environ["HOME"] = \
   925         os.path.join(HGTMP, os.path.basename(test))
   925         os.path.join(HGTMP, os.path.basename(test))
   926     os.mkdir(testtmp)
   926     os.mkdir(testtmp)