]> Cypherpunks repositories - gostls13.git/commitdiff
test/run: honor $TMPDIR
authorShenghou Ma <minux.ma@gmail.com>
Sat, 18 Feb 2012 21:15:12 +0000 (16:15 -0500)
committerRuss Cox <rsc@golang.org>
Sat, 18 Feb 2012 21:15:12 +0000 (16:15 -0500)
R=golang-dev, rsc
CC=golang-dev
https://golang.org/cl/5676094

test/run

index 67526958d98ce52d0084ff995b0dbfcc3fec92a6..8acbc3d45ec3785e7833707add4a9c8370a2c692 100755 (executable)
--- a/test/run
+++ b/test/run
@@ -36,9 +36,9 @@ PATH=${GOBIN:-$GOROOT/bin}:`pwd`:/bin:/usr/bin:/usr/local/bin
 # TODO: We add the tool directory to the PATH to avoid thinking about a better way.
 PATH="$GOTOOLDIR:$PATH"
 
-RUNFILE="/tmp/gorun-$$-$USER"
-TMP1FILE="/tmp/gotest1-$$-$USER"
-TMP2FILE="/tmp/gotest2-$$-$USER"
+RUNFILE="${TMPDIR:-/tmp}/gorun-$$-$USER"
+TMP1FILE="${TMPDIR:-/tmp}/gotest1-$$-$USER"
+TMP2FILE="${TMPDIR:-/tmp}/gotest2-$$-$USER"
 
 # don't run the machine out of memory: limit individual processes to 4GB.
 # on thresher, 3GB suffices to run the tests; with 2GB, peano fails.