##// END OF EJS Templates
imported patch test-check
Dirkjan Ochtman -
r6982:9fc5bf4a default
parent child Browse files
Show More
@@ -202,6 +202,8 b' def install_hg():'
202 202 os.environ["PYTHONPATH"] = pythonpath
203 203
204 204 use_correct_python()
205 global hgpkg
206 hgpkg = _hgpath()
205 207
206 208 if coverage:
207 209 vlog("# Installing coverage wrapper")
@@ -456,6 +458,16 b' BINDIR = os.path.join(INST, "bin")'
456 458 PYTHONDIR = os.path.join(INST, "lib", "python")
457 459 COVERAGE_FILE = os.path.join(TESTDIR, ".coverage")
458 460
461 def _hgpath():
462 cmd = '%s -c "import mercurial; print mercurial.__path__[0]"'
463 hgpath = os.popen(cmd % python)
464 path = hgpath.read().strip()
465 hgpath.close()
466 return path
467
468 expecthg = os.path.join(HGTMP, 'install', 'lib', 'python', 'mercurial')
469 hgpkg = None
470
459 471 def run_children(tests):
460 472 if not options.with_hg:
461 473 install_hg()
@@ -512,6 +524,9 b' def run_children(tests):'
512 524 print "Skipped %s: %s" % (s[0], s[1])
513 525 for s in fails:
514 526 print "Failed %s: %s" % (s[0], s[1])
527
528 if hgpkg != expecthg:
529 print '# Tested unexpected mercurial: %s' % hgpkg
515 530 print "# Ran %d tests, %d skipped, %d failed." % (
516 531 tested, skipped, failed)
517 532 sys.exit(failures != 0)
@@ -525,6 +540,9 b' def run_tests(tests):'
525 540 if not options.with_hg:
526 541 install_hg()
527 542
543 if hgpkg != expecthg:
544 print '# Testing unexpected mercurial: %s' % hgpkg
545
528 546 if options.timeout > 0:
529 547 try:
530 548 signal.signal(signal.SIGALRM, alarmed)
@@ -585,6 +603,8 b' def run_tests(tests):'
585 603 print "Skipped %s: %s" % s
586 604 for s in fails:
587 605 print "Failed %s: %s" % s
606 if hgpkg != expecthg:
607 print '# Tested unexpected mercurial: %s' % hgpkg
588 608 print "# Ran %d tests, %d skipped, %d failed." % (
589 609 tested, skipped, failed)
590 610
General Comments 0
You need to be logged in to leave comments. Login now