Changeset eea20cd for tests


Ignore:
Timestamp:
Sep 12, 2019, 11:00:28 AM (5 years ago)
Author:
Thierry Delisle <tdelisle@…>
Branches:
ADT, arm-eh, ast-experimental, enum, forall-pointer-decay, jacob/cs343-translation, jenkins-sandbox, master, new-ast, new-ast-unique-expr, pthread-emulation, qualifiedEnum
Children:
31d8f4d
Parents:
6716d78
Message:

Fixed git hash in python script with dry-run enabled

File:
1 edited

Legend:

Unmodified
Added
Removed
  • tests/pybin/tools.py

    r6716d78 reea20cd  
    2323
    2424# helper functions to run terminal commands
    25 def sh(*cmd, timeout = False, output_file = None, input_file = None, input_text = None, error = subprocess.STDOUT):
     25def sh(*cmd, timeout = False, output_file = None, input_file = None, input_text = None, error = subprocess.STDOUT, ignore_dry_run = False):
    2626        cmd = list(cmd)
    2727
     
    3030
    3131        # if this is a dry_run, only print the commands that would be ran
    32         if settings.dry_run :
     32        if settings.dry_run and not ignore_dry_run:
    3333                cmd = "{} cmd: {}".format(os.getcwd(), ' '.join(cmd))
    3434                if output_file and not isinstance(output_file, int):
     
    287287        distcc_hash = os.path.join(settings.SRCDIR, '../tools/build/distcc_hash')
    288288        config = "%s-%s" % (settings.arch.target, settings.debug.path)
    289         _, out = sh(distcc_hash, config, output_file=subprocess.PIPE)
     289        _, out = sh(distcc_hash, config, output_file=subprocess.PIPE, ignore_dry_run=True)
    290290        return out.strip()
    291291
Note: See TracChangeset for help on using the changeset viewer.