integration.BeforeTest can be run without leak-detection.

This commit is contained in:
Piotr Tabor
2021-05-27 18:44:14 +02:00
parent b3f16d6691
commit 3f13d3a2d5
13 changed files with 116 additions and 37 deletions

View File

@ -1288,16 +1288,8 @@ type ClusterV3 struct {
// for each cluster member.
func NewClusterV3(t testutil.TB, cfg *ClusterConfig) *ClusterV3 {
t.Helper()
testutil.SkipTestIfShortMode(t, "Cannot create clusters in --short tests")
wd, err := os.Getwd()
if err != nil {
t.Fatal(err)
}
if !strings.HasPrefix(wd, os.TempDir()) {
t.Errorf("Working directory '%s' expected to be in temp-dir ('%s')."+
"Have you executed integration.BeforeTest(t) ?", wd, os.TempDir())
}
assertInTestContext(t)
cfg.UseGRPC = true