Skip to content
Merged
Show file tree
Hide file tree
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
fix error message and test
  • Loading branch information
weshayutin committed Apr 16, 2025
commit dcb16a72bbd52880ea1ec195cf6db4536919b613
6 changes: 3 additions & 3 deletions pkg/exposer/host_path.go
Original file line number Diff line number Diff line change
Expand Up @@ -62,9 +62,9 @@ func GetPodVolumeHostPath(ctx context.Context, pod *corev1.Pod, volumeName strin

path, err := singlePathMatch(pathGlob, fs, logger)
if err != nil {
return datapath.AccessPoint{}, errors.Wrapf(err, `error identifying unique volume path
on host for volume %s in pod %s, or the DPA spec.configuration.velero.disableFsBackup
is set to true, please contact your administrator. `,
return datapath.AccessPoint{}, errors.Wrapf(err, "error identifying unique volume path "+
"on host for volume %s in pod %s, or the DPA spec.configuration.velero.disableFsBackup "+
"is set to true, please contact your administrator. ",
volumeName, pod.Name)
}

Expand Down
2 changes: 1 addition & 1 deletion pkg/exposer/host_path_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -65,7 +65,7 @@ func TestGetPodVolumeHostPath(t *testing.T) {
},
pod: builder.ForPod(velerov1api.DefaultNamespace, "fake-pod-2").Result(),
pvc: "fake-pvc-1",
err: "error identifying unique volume path on host for volume fake-pvc-1 in pod fake-pod-2: fake-error-2",
err: "error identifying unique volume path on host for volume fake-pvc-1 in pod fake-pod-2, or the DPA spec.configuration.velero.disableFsBackup is set to true, please contact your administrator. : fake-error-2",
},
{
name: "get block volume dir success",
Expand Down