Skip to content

Commit 120bc39

Browse files
authored
Check $NODE environment variable when looking for node (#1792)
This allows me to run tests on a system where the default installed node is not recent enough.
1 parent 33e337e commit 120bc39

File tree

2 files changed

+3
-2
lines changed

2 files changed

+3
-2
lines changed

scripts/fuzz_relooper.py

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -372,7 +372,8 @@ def get_phi(j):
372372
stdout=subprocess.PIPE,
373373
stderr=subprocess.PIPE).communicate()[0]
374374
print '-'
375-
slow_out = subprocess.Popen(['nodejs', 'fuzz.slow.js'],
375+
node = os.getenv('NODE', 'nodejs')
376+
slow_out = subprocess.Popen([node, 'fuzz.slow.js'],
376377
stdout=subprocess.PIPE,
377378
stderr=subprocess.PIPE).communicate()[0]
378379
print '_'

scripts/test/shared.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -157,7 +157,7 @@ def is_exe(fpath):
157157
which('gcc') or which('clang'))
158158
NATIVEXX = (os.environ.get('CXX') or which('mingw32-g++') or
159159
which('g++') or which('clang++'))
160-
NODEJS = which('nodejs') or which('node')
160+
NODEJS = os.getenv('NODE', which('nodejs') or which('node'))
161161
MOZJS = which('mozjs') or which('spidermonkey')
162162
EMCC = which('emcc')
163163

0 commit comments

Comments
 (0)