Add more sidecar tests and cleanup sidecar code

Signed-off-by: Grant Griffiths <grant@portworx.com>
This commit is contained in:
Grant Griffiths
2020-03-04 20:25:31 -08:00
parent 3dd4e07599
commit fe1c355fa9
4 changed files with 209 additions and 46 deletions

View File

@@ -68,6 +68,11 @@ var class6Parameters = map[string]string{
utils.PrefixedSnapshotterListSecretNamespaceKey: "default",
}
var class7Annotations = map[string]string{
utils.AnnDeletionSecretRefName: "secret-x",
utils.AnnDeletionSecretRefNamespace: "default-x",
}
var snapshotClasses = []*crdv1.VolumeSnapshotClass{
{
TypeMeta: metav1.TypeMeta{
@@ -107,10 +112,11 @@ var snapshotClasses = []*crdv1.VolumeSnapshotClass{
Kind: "VolumeSnapshotClass",
},
ObjectMeta: metav1.ObjectMeta{
Name: invalidSecretClass,
Name: invalidSecretClass,
Annotations: class7Annotations,
},
Driver: mockDriverName,
Parameters: class3Parameters,
Parameters: class2Parameters,
DeletionPolicy: crdv1.VolumeSnapshotContentDelete,
},
{