From e1e2d702c4cf06ff4daad5154036aff714e7520c Mon Sep 17 00:00:00 2001 From: Michail Kargakis Date: Thu, 30 Mar 2017 18:43:40 +0200 Subject: [PATCH] Log replica sets/pods for recreate test --- test/e2e/framework/util.go | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/test/e2e/framework/util.go b/test/e2e/framework/util.go index 9859ed5b539..bc8ae58a118 100644 --- a/test/e2e/framework/util.go +++ b/test/e2e/framework/util.go @@ -3388,6 +3388,13 @@ func WatchRecreateDeployment(c clientset.Interface, d *extensions.Deployment) er status = d.Status if d.Status.UpdatedReplicas > 0 && d.Status.Replicas != d.Status.UpdatedReplicas { + _, allOldRSs, err := deploymentutil.GetOldReplicaSets(d, c) + newRS, nerr := deploymentutil.GetNewReplicaSet(d, c) + if err == nil && nerr == nil { + Logf("%+v", d) + logReplicaSetsOfDeployment(d, allOldRSs, newRS) + logPodsOfDeployment(c, d, append(allOldRSs, newRS), false) + } return false, fmt.Errorf("deployment %q is running new pods alongside old pods: %#v", d.Name, status) }