tests: skip cases that depend on test server when -short flag set (#10576)
This commit is contained in:
parent
ae48b8314b
commit
db250e2114
|
@ -50,6 +50,11 @@ func makeClientWithConfig(
|
|||
t *testing.T,
|
||||
cb1 configCallback,
|
||||
cb2 testutil.ServerConfigCallback) (*Client, *testutil.TestServer) {
|
||||
// Skip test when -short flag provided; any tests that create a test
|
||||
// server will take at least 100ms which is undesirable for -short
|
||||
if testing.Short() {
|
||||
t.Skip("too slow for testing.Short")
|
||||
}
|
||||
|
||||
// Make client config
|
||||
conf := DefaultConfig()
|
||||
|
|
|
@ -24,6 +24,12 @@ import (
|
|||
)
|
||||
|
||||
func makeClient(t *testing.T) (*api.Client, *testutil.TestServer) {
|
||||
// Skip test when -short flag provided; any tests that create a test server
|
||||
// will take at least 100ms which is undesirable for -short
|
||||
if testing.Short() {
|
||||
t.Skip("too slow for testing.Short")
|
||||
}
|
||||
|
||||
// Make client config
|
||||
conf := api.DefaultConfig()
|
||||
|
||||
|
|
Loading…
Reference in New Issue