Speed up pkg/volume/csi unit tests

This commit is contained in:
wzshiming
2021-02-04 18:55:29 +08:00
committed by Shiming Zhang
parent 2014d37e51
commit bc3d9252bc
3 changed files with 100 additions and 68 deletions

View File

@@ -910,7 +910,7 @@ func TestPluginNewAttacher(t *testing.T) {
t.Fatalf("failed to create new attacher: %v", err)
}
csiAttacher := getCsiAttacherFromVolumeAttacher(attacher)
csiAttacher := getCsiAttacherFromVolumeAttacher(attacher, testWatchTimeout)
if csiAttacher.plugin == nil {
t.Error("plugin not set for attacher")
}
@@ -931,7 +931,7 @@ func TestPluginNewDetacher(t *testing.T) {
t.Fatalf("failed to create new detacher: %v", err)
}
csiDetacher := getCsiAttacherFromVolumeDetacher(detacher)
csiDetacher := getCsiAttacherFromVolumeDetacher(detacher, testWatchTimeout)
if csiDetacher.plugin == nil {
t.Error("plugin not set for detacher")
}