mirror of
https://github.com/k3s-io/kubernetes.git
synced 2025-07-21 19:01:49 +00:00
Merge pull request #101536 from jingxu97/apr/mounttest
Add unit test for clean up mountpoint logic if path does not exist
This commit is contained in:
commit
0dcf9c0826
@ -53,6 +53,12 @@ func TestDoCleanupMountPoint(t *testing.T) {
|
||||
return MountPoint{Device: "/dev/sdb", Path: path}, nil, nil
|
||||
},
|
||||
},
|
||||
"path-not-exist": {
|
||||
prepare: func(base string) (MountPoint, error, error) {
|
||||
path := filepath.Join(base, testMount)
|
||||
return MountPoint{Device: "/dev/sdb", Path: path}, nil, nil
|
||||
},
|
||||
},
|
||||
"mount-corrupted": {
|
||||
prepare: func(base string) (MountPoint, error, error) {
|
||||
path := filepath.Join(base, testMount)
|
||||
|
Loading…
Reference in New Issue
Block a user