diff options
author | Alon Zakai <alonzakai@gmail.com> | 2013-08-30 11:21:48 -0700 |
---|---|---|
committer | Alon Zakai <alonzakai@gmail.com> | 2013-08-30 11:21:48 -0700 |
commit | b5b49215d4a40566380a769f47a9c1cce74a28b0 (patch) | |
tree | 68308b6059798a81f24f6a8a1ac28a0091c5d066 /tools/jsrun.py | |
parent | 1cc28b8e9e94267041bc71afebfbbe3059db4a3f (diff) | |
parent | b895cdc7df2085d324003c9df582a3dcc1927697 (diff) |
Merge branch 'incoming'
Diffstat (limited to 'tools/jsrun.py')
-rw-r--r-- | tools/jsrun.py | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/tools/jsrun.py b/tools/jsrun.py index 571e9cee..91038f6e 100644 --- a/tools/jsrun.py +++ b/tools/jsrun.py @@ -12,13 +12,14 @@ def timeout_run(proc, timeout, note='unnamed process', full_output=False): out = proc.communicate() return '\n'.join(out) if full_output else out[0] -def run_js(filename, engine=None, args=[], check_timeout=False, stdout=PIPE, stderr=None, cwd=None, full_output=False): +def run_js(filename, engine=None, args=[], check_timeout=False, stdin=None, stdout=PIPE, stderr=None, cwd=None, full_output=False): if type(engine) is not list: engine = [engine] command = engine + [filename] + (['--'] if 'd8' in engine[0] or 'jsc' in engine[0] else []) + args return timeout_run( Popen( command, + stdin=stdin, stdout=stdout, stderr=stderr, cwd=cwd), |