Skip to content

Commit

Permalink
Revert "Expose VSC SourceVolumeMode"
Browse files Browse the repository at this point in the history
This reverts commit 7580538.

Signed-off-by: MICHAEL S FRUCHTMAN <[email protected]>
msfrucht committed Oct 14, 2024
1 parent f02613d commit d9b278e
Showing 3 changed files with 0 additions and 5 deletions.
1 change: 0 additions & 1 deletion changelogs/unreleased/8261-msfrucht

This file was deleted.

1 change: 0 additions & 1 deletion pkg/exposer/csi_snapshot.go
Original file line number Diff line number Diff line change
@@ -369,7 +369,6 @@ func (e *csiSnapshotExposer) createBackupVSC(ctx context.Context, ownerObject co
DeletionPolicy: snapshotv1api.VolumeSnapshotContentDelete,
Driver: snapshotVSC.Spec.Driver,
VolumeSnapshotClassName: snapshotVSC.Spec.VolumeSnapshotClassName,
SourceVolumeMode: snapshotVSC.Spec.SourceVolumeMode,
},
}

3 changes: 0 additions & 3 deletions pkg/exposer/csi_snapshot_test.go
Original file line number Diff line number Diff line change
@@ -109,7 +109,6 @@ func TestExpose(t *testing.T) {
}

snapshotHandle := "fake-handle"
sourceVolumeMode := corev1.PersistentVolumeFilesystem
vscObj := &snapshotv1api.VolumeSnapshotContent{
ObjectMeta: metav1.ObjectMeta{
Name: vscName,
@@ -122,7 +121,6 @@ func TestExpose(t *testing.T) {
DeletionPolicy: snapshotv1api.VolumeSnapshotContentDelete,
Driver: "fake-driver",
VolumeSnapshotClassName: &snapshotClass,
SourceVolumeMode: &sourceVolumeMode,
},
Status: &snapshotv1api.VolumeSnapshotContentStatus{
RestoreSize: &restoreSize,
@@ -524,7 +522,6 @@ func TestExpose(t *testing.T) {
assert.Equal(t, expectedVSC.Spec.DeletionPolicy, vscObj.Spec.DeletionPolicy)
assert.Equal(t, expectedVSC.Spec.Driver, vscObj.Spec.Driver)
assert.Equal(t, *expectedVSC.Spec.VolumeSnapshotClassName, *vscObj.Spec.VolumeSnapshotClassName)
assert.Equal(t, *expectedVSC.Spec.SourceVolumeMode, *vscObj.Spec.SourceVolumeMode)

if test.expectedVolumeSize != nil {
assert.Equal(t, *test.expectedVolumeSize, backupPVC.Spec.Resources.Requests[corev1.ResourceStorage])

0 comments on commit d9b278e

Please sign in to comment.