blob: 6513451df856c4eb1bcd74da1d102c9395d84ad0 [file] [log] [blame]
# smoke test for complex build configuration
go build -o complex.exe complex
[exec:gccgo] go build -compiler=gccgo -o complex.exe complex
-- complex/main.go --
package main
import (
_ "complex/nest/sub/test12"
_ "complex/nest/sub/test23"
"complex/w"
"v"
)
func main() {
println(v.Hello + " " + w.World)
}
-- complex/nest/sub/test12/p.go --
package test12
// Check that vendor/v1 is used but vendor/v2 is NOT used (sub/vendor/v2 wins).
import (
"v1"
"v2"
)
const x = v1.ComplexNestVendorV1
const y = v2.ComplexNestSubVendorV2
-- complex/nest/sub/test23/p.go --
package test23
// Check that vendor/v3 is used but vendor/v2 is NOT used (sub/vendor/v2 wins).
import (
"v2"
"v3"
)
const x = v3.ComplexNestVendorV3
const y = v2.ComplexNestSubVendorV2
-- complex/nest/sub/vendor/v2/v2.go --
package v2
const ComplexNestSubVendorV2 = true
-- complex/nest/vendor/v1/v1.go --
package v1
const ComplexNestVendorV1 = true
-- complex/nest/vendor/v2/v2.go --
package v2
const ComplexNestVendorV2 = true
-- complex/nest/vendor/v3/v3.go --
package v3
const ComplexNestVendorV3 = true
-- complex/vendor/v/v.go --
package v
const Hello = "hello"
-- complex/w/w.go --
package w
const World = "world"