On Solaris /bin is a symlink to /usr/bin, so running "pwd" in
the directory "/bin" prints out "/usr/bin".
R=rsc, r, bradfitz
CC=golang-dev
https://golang.org/cl/
4559043
var b bytes.Buffer
io.Copy(&b, r)
output := b.String()
- if output != expect {
+ // Accept /usr prefix because Solaris /bin is symlinked to /usr/bin.
+ if output != expect && output != "/usr"+expect {
t.Errorf("exec %q returned %q wanted %q",
strings.Join(append([]string{cmd}, args...), " "), output, expect)
}