Seed math/rand in TestMain before tests are executed

This commit is contained in:
Mikhail Mazurskiy
2018-10-11 21:57:43 +11:00
parent f5e9c0473c
commit 55bc668f8d
3 changed files with 4 additions and 2 deletions

View File

@@ -256,7 +256,6 @@ func TestPersistentVolumeBindRace(t *testing.T) {
glog.V(2).Infof("TestPersistentVolumeBindRace claims created")
// putting a bind manually on a pv should only match the claim it is bound to
rand.Seed(time.Now().Unix())
claim := claims[rand.Intn(maxClaims-1)]
claimRef, err := ref.GetReference(legacyscheme.Scheme, claim)
if err != nil {