Home | History | Annotate | Download | only in go
      1 // Copyright 2014 The Go Authors. All rights reserved.
      2 // Use of this source code is governed by a BSD-style
      3 // license that can be found in the LICENSE file.
      4 
      5 // This file contains extra hooks for testing the go command.
      6 // It is compiled into the Go binary only when building the
      7 // test copy; it does not get compiled into the standard go
      8 // command, so these testing hooks are not present in the
      9 // go command that everyone uses.
     10 
     11 // +build testgo
     12 
     13 package main
     14 
     15 import "os"
     16 
     17 func init() {
     18 	if v := os.Getenv("TESTGO_IS_GO_RELEASE"); v != "" {
     19 		isGoRelease = v == "1"
     20 	}
     21 }
     22