e2e: adjust deletion, filesystem and block tests for migration volume

this commit create and make use of migration secret in the requests and
validate various csi operations

Signed-off-by: Humble Chirammal <hchiramm@redhat.com>
This commit is contained in:
Humble Chirammal
2021-10-15 12:14:10 +05:30
committed by mergify[bot]
parent 6aec858cba
commit de57fa1804
4 changed files with 178 additions and 8 deletions

View File

@ -221,7 +221,7 @@ func validateRBDStaticPV(f *framework.Framework, appPath string, isBlock, checkI
return err
}
func validateRBDStaticMigrationPV(f *framework.Framework, appPath string, isBlock bool) error {
func validateRBDStaticMigrationPV(f *framework.Framework, appPath, nodeSecretName string, isBlock bool) error {
opt := make(map[string]string)
var (
rbdImageName = "test-static-pv"
@ -254,6 +254,9 @@ func validateRBDStaticMigrationPV(f *framework.Framework, appPath string, isBloc
if e != "" {
return fmt.Errorf("failed to create rbd image %s", e)
}
if nodeSecretName == "" {
nodeSecretName = rbdNodePluginSecretName
}
opt["migration"] = "true"
opt["clusterID"] = getMonsHash(mon)
@ -265,7 +268,7 @@ func validateRBDStaticMigrationPV(f *framework.Framework, appPath string, isBloc
pvName,
rbdImageName,
size,
rbdNodePluginSecretName,
nodeSecretName,
cephCSINamespace,
sc,
"rbd.csi.ceph.com",