1
0
mirror of https://github.com/golang/go synced 2024-11-17 10:24:48 -07:00

Add go.mod and Module=ON to test script, change directories for tests

This commit is contained in:
Liberatys 2019-04-24 16:31:33 +02:00
parent ec8fe14249
commit e0964983e1
No known key found for this signature in database
GPG Key ID: 721C85290157A24C

View File

@ -1,7 +1,8 @@
env GO111MODULE=on
# Check for correct naming of temporary executable
#Test for single file specified
cd m/x/y/z/
cd x/y/z
go run foo.go
stderr 'foo'
@ -23,7 +24,7 @@ func main() {
println(filepath.Base(os.Args[0]))
}
-- m/x/y/z/foo.go --
-- x/y/z/foo.go --
package main
import(
"os"
@ -33,7 +34,7 @@ func main() {
println(filepath.Base(os.Args[0]))
}
-- m/x/y/z/foo.go --
-- x/y/z/foo.go --
package main
import(
"os"
@ -43,3 +44,5 @@ func main() {
println(filepath.Base(os.Args[0]))
}
-- go.mod --
module m