summaryrefslogtreecommitdiff
path: root/test/run.go
diff options
context:
space:
mode:
authorShenghou Ma <minux.ma@gmail.com>2012-07-31 23:26:33 -0400
committerShenghou Ma <minux.ma@gmail.com>2012-07-31 23:26:33 -0400
commit4ec02c03879039a86d6b9a4c31c3d052e735ee10 (patch)
tree3ee60247953a4b1443a9adf01604161c389bb5a4 /test/run.go
parentd317f63f15758f152b60df71418fcdfe28480cb2 (diff)
downloadgo-4ec02c03879039a86d6b9a4c31c3d052e735ee10.tar.gz
test/run.go: fix compiledir test on windows
we can't import "./bug0" on windows, as it will trigger "import path contains invalid character ':'" error. instead, we pass "-D." and "-I." to gc to override this behavior. this idea is due to remyoudompheng. R=golang-dev, r, alex.brainman, remyoudompheng CC=golang-dev http://codereview.appspot.com/6441074
Diffstat (limited to 'test/run.go')
-rw-r--r--test/run.go4
1 files changed, 2 insertions, 2 deletions
diff --git a/test/run.go b/test/run.go
index e1d97e9ee..2b26a5b01 100644
--- a/test/run.go
+++ b/test/run.go
@@ -172,7 +172,7 @@ type test struct {
donec chan bool // closed when done
src string
- action string // "compile", "build", "run", "errorcheck", "skip", "runoutput"
+ action string // "compile", "build", "run", "errorcheck", "skip", "runoutput", "compiledir"
tempDir string
err error
@@ -315,7 +315,7 @@ func (t *test) run() {
}
for _, gofile := range files {
afile := strings.Replace(gofile.Name(), ".go", "."+letter, -1)
- out, err := runcmd("go", "tool", gc, "-e", "-o", afile, filepath.Join(longdir, gofile.Name()))
+ out, err := runcmd("go", "tool", gc, "-e", "-D.", "-I.", "-o", afile, filepath.Join(longdir, gofile.Name()))
if err != nil {
t.err = fmt.Errorf("%s\n%s", err, out)
break