blob: 5ceb154a48ded53fe11d685ba2deeaacb234e89b [file] [log] [blame]
# This test verifies that line numbers are included in module import errors.
# Verifies golang.org/issue/34393.
go list -e -deps -f '{{with .Error}}{{.Pos}}: {{.Err}}{{end}}' ./main
stdout 'bad[/\\]bad.go:3:8: malformed module path "string": missing dot in first path element'
-- go.mod --
module m
go 1.13
-- main/main.go --
package main
import _ "m/bad"
func main() {}
-- bad/bad.go --
package bad
import _ "string"