mirror of
https://github.com/optim-enterprises-bv/kubernetes.git
synced 2025-11-02 11:18:16 +00:00
Fix tests to test for new behavior
This commit is contained in:
@@ -101,7 +101,7 @@ func TestCleanupOrphanedPodDirs(t *testing.T) {
|
|||||||
},
|
},
|
||||||
validateFunc: func(kubelet *Kubelet) error {
|
validateFunc: func(kubelet *Kubelet) error {
|
||||||
podDir := kubelet.getPodDir("pod1uid")
|
podDir := kubelet.getPodDir("pod1uid")
|
||||||
return validateDirExists(filepath.Join(podDir, "volumes/plugin/name"))
|
return validateDirNotExists(filepath.Join(podDir, "volumes/plugin/name"))
|
||||||
},
|
},
|
||||||
},
|
},
|
||||||
"pod-doesnot-exist-with-subpath": {
|
"pod-doesnot-exist-with-subpath": {
|
||||||
@@ -111,7 +111,7 @@ func TestCleanupOrphanedPodDirs(t *testing.T) {
|
|||||||
},
|
},
|
||||||
validateFunc: func(kubelet *Kubelet) error {
|
validateFunc: func(kubelet *Kubelet) error {
|
||||||
podDir := kubelet.getPodDir("pod1uid")
|
podDir := kubelet.getPodDir("pod1uid")
|
||||||
return validateDirExists(filepath.Join(podDir, "volume-subpaths/volume/container/index"))
|
return validateDirNotExists(filepath.Join(podDir, "volume-subpaths/volume/container/index"))
|
||||||
},
|
},
|
||||||
},
|
},
|
||||||
"pod-doesnot-exist-with-subpath-top": {
|
"pod-doesnot-exist-with-subpath-top": {
|
||||||
@@ -121,7 +121,7 @@ func TestCleanupOrphanedPodDirs(t *testing.T) {
|
|||||||
},
|
},
|
||||||
validateFunc: func(kubelet *Kubelet) error {
|
validateFunc: func(kubelet *Kubelet) error {
|
||||||
podDir := kubelet.getPodDir("pod1uid")
|
podDir := kubelet.getPodDir("pod1uid")
|
||||||
return validateDirExists(filepath.Join(podDir, "volume-subpaths"))
|
return validateDirNotExists(filepath.Join(podDir, "volume-subpaths"))
|
||||||
},
|
},
|
||||||
},
|
},
|
||||||
// TODO: test volume in volume-manager
|
// TODO: test volume in volume-manager
|
||||||
|
|||||||
Reference in New Issue
Block a user