Skip to content

Commit 7d917dc

Browse files
gibfahnitaloacasas
authored andcommitted
test: fix temp-dir option in tools/test.py
If a temp-dir is specified and already exists, the NODE_TEST_DIR environment variable will never be set. This fixes that. PR-URL: #10723 Reviewed-By: Colin Ihrig <[email protected]> Reviewed-By: James M Snell <[email protected]> Reviewed-By: Sakthipriyan Vairamani <[email protected]> Reviewed-By: Michael Dawson <[email protected]>
1 parent 6b54024 commit 7d917dc

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

tools/test.py

+1-1
Original file line numberDiff line numberDiff line change
@@ -1628,9 +1628,9 @@ def Main():
16281628

16291629
tempdir = os.environ.get('NODE_TEST_DIR') or options.temp_dir
16301630
if tempdir:
1631+
os.environ['NODE_TEST_DIR'] = tempdir
16311632
try:
16321633
os.makedirs(tempdir)
1633-
os.environ['NODE_TEST_DIR'] = tempdir
16341634
except OSError as exception:
16351635
if exception.errno != errno.EEXIST:
16361636
print "Could not create the temporary directory", options.temp_dir

0 commit comments

Comments
 (0)