Update tests to prepare for graceful deletion
For cases where we want to immediately cleanup the pod, start using gracePeriod 0 in test cases.
This commit is contained in:
@@ -232,7 +232,7 @@ var deleteNow string = `
|
||||
{
|
||||
"kind": "DeleteOptions",
|
||||
"apiVersion": "` + testapi.Version() + `",
|
||||
"gracePeriodSeconds": null%s
|
||||
"gracePeriodSeconds": 0%s
|
||||
}
|
||||
`
|
||||
|
||||
|
@@ -277,7 +277,7 @@ func DoTestUnschedulableNodes(t *testing.T, restClient *client.Client, nodeStore
|
||||
t.Logf("Test %d: Pod got scheduled on a schedulable node", i)
|
||||
}
|
||||
|
||||
err = restClient.Pods(api.NamespaceDefault).Delete(myPod.Name, nil)
|
||||
err = restClient.Pods(api.NamespaceDefault).Delete(myPod.Name, api.NewDeleteOptions(0))
|
||||
if err != nil {
|
||||
t.Errorf("Failed to delete pod: %v", err)
|
||||
}
|
||||
|
Reference in New Issue
Block a user