def main(): try: options = parse_arguments(sys.argv) except OptError as e: print str(e) sys.exit(1) if options['checkout']: if repo_has_local_changes(): print >> sys.stderr, "Found local changes, bailing out" sys.exit(1) print "Pulling the latest updates to long-test branch" git_checkout(long_test_branch) exec_self([no_checkout_arg] + sys.argv[1:]) if options['make']: # Clean the repo do_test("cd ../src && make -j clean", cmd_format="make") # Build release build with symbols do_test("cd ../src && make -j DEBUG=0 SYMBOLS=1 FAST_PERFMON=0", cmd_format="make") # Make sure auxillary tools compile do_test("cd ../bench/stress-client/; make clean; make -j MYSQL=0 LIBMEMCACHED=0 stress libstress.so", cmd_format="make") ts = datetime.now().replace(microsecond=0) dir_name = "%s-%s" % (ts.isoformat(), repo_version()) test_dir = TestDir(os.path.expanduser(os.path.join(long_test_logs_dir, dir_name))) print "Test directory: %s" % test_dir.name set_signal_handler() long_test_function(opts=options, test_dir=test_dir)
def main(): try: options = parse_arguments(sys.argv) except OptError as e: print str(e) sys.exit(1) if options['checkout']: if repo_has_local_changes(): print >> sys.stderr, "Found local changes, bailing out" sys.exit(1) print "Pulling the latest updates to long-test branch" git_checkout(long_test_branch) exec_self([no_checkout_arg] + sys.argv[1:]) if options['make']: # Clean the repo do_test("cd ../src && make -j clean", cmd_format="make") # Build release build with symbols do_test("cd ../src && make -j DEBUG=0 SYMBOLS=1 FAST_PERFMON=0", cmd_format="make") # Make sure auxillary tools compile do_test( "cd ../bench/stress-client/; make clean; make -j MYSQL=0 LIBMEMCACHED=0 stress libstress.so", cmd_format="make") ts = datetime.now().replace(microsecond=0) dir_name = "%s-%s" % (ts.isoformat(), repo_version()) test_dir = TestDir( os.path.expanduser(os.path.join(long_test_logs_dir, dir_name))) print "Test directory: %s" % test_dir.name set_signal_handler() long_test_function(opts=options, test_dir=test_dir)
def git_checkout(branch): do_test( "git fetch -f origin {b}:refs/remotes/origin/{b} && git checkout -f origin/{b}" .format(b=branch))
def git_checkout(branch): do_test("git fetch -f origin {b}:refs/remotes/origin/{b} && git checkout -f origin/{b}".format(b=branch))