go.crypto/ssh/test: skip tests during -short mode

This proposal effectively disables all the ssh/test tests when run with the -short flag supplied.

For developers and users of this package, there should be no change unless they are in the habbit of always supplying -short, which I belive is untrue.

For the CI dashboard the effect should be that these tests, which are really not portable enough to run reliably on all our various builders, are disabled.

LGTM=adg
R=adg, agl, hanwen
CC=golang-codereviews
https://golang.org/cl/125860043
This commit is contained in:
Dave Cheney
2014-08-08 11:42:28 +10:00
parent b7f382b979
commit ed03dad8de
+3
View File
@@ -224,6 +224,9 @@ func writeFile(path string, contents []byte) {
// newServer returns a new mock ssh server.
func newServer(t *testing.T) *server {
if testing.Short() {
t.Skip("skipping test due to -short")
}
dir, err := ioutil.TempDir("", "sshtest")
if err != nil {
t.Fatal(err)