Skip to content

Commit

Permalink
Update cloudbackup to v0.31.0
Browse files Browse the repository at this point in the history
  • Loading branch information
lpabon committed Nov 28, 2018
1 parent 832c8dd commit ee0bc48
Showing 1 changed file with 12 additions and 12 deletions.
24 changes: 12 additions & 12 deletions pkg/sanity/cloudbackup.go
Original file line number Diff line number Diff line change
Expand Up @@ -30,12 +30,12 @@ import (

func getBackupId(bc api.OpenStorageCloudBackupClient, clusterId, volumeId, credentialId string) string {

enumerateReq := &api.SdkCloudBackupEnumerateRequest{
enumerateReq := &api.SdkCloudBackupEnumerateWithFiltersRequest{
ClusterId: clusterId,
SrcVolumeId: volumeId,
CredentialId: credentialId,
}
enumerateResp, err := bc.Enumerate(context.Background(), enumerateReq)
enumerateResp, err := bc.EnumerateWithFilters(context.Background(), enumerateReq)
Expect(err).NotTo(HaveOccurred())
Expect(enumerateResp).NotTo(BeNil())
Expect(enumerateResp.GetBackups()).NotTo(BeEmpty())
Expand Down Expand Up @@ -367,9 +367,9 @@ var _ = Describe("Cloud backup [OpenStorageCluster]", func() {

By("Enumerating the cloud backups")

enumerateResp, err := bc.Enumerate(
enumerateResp, err := bc.EnumerateWithFilters(
context.Background(),
&api.SdkCloudBackupEnumerateRequest{
&api.SdkCloudBackupEnumerateWithFiltersRequest{
ClusterId: clusterID,
CredentialId: credID,
SrcVolumeId: volID,
Expand Down Expand Up @@ -397,13 +397,13 @@ var _ = Describe("Cloud backup [OpenStorageCluster]", func() {

By("Doing Backup on " + provider)

enumerateReq := &api.SdkCloudBackupEnumerateRequest{
enumerateReq := &api.SdkCloudBackupEnumerateWithFiltersRequest{
ClusterId: clusterID,
SrcVolumeId: "this-doesnt-exist",
CredentialId: credID,
}

resp, err := bc.Enumerate(context.Background(), enumerateReq)
resp, err := bc.EnumerateWithFilters(context.Background(), enumerateReq)
Expect(err).NotTo(HaveOccurred())
Expect(resp.GetBackups()).To(BeEmpty())
}
Expand All @@ -428,13 +428,13 @@ var _ = Describe("Cloud backup [OpenStorageCluster]", func() {

// By("Doing Backup on " + provider)

// enumerateReq := &api.SdkCloudBackupEnumerateRequest{
// enumerateReq := &api.SdkCloudBackupEnumerateWithFiltersRequest{
// ClusterId: clusterID,
// SrcVolumeId: "",
// CredentialId: credID,
// }

// enumerateResp, err := bc.Enumerate(context.Background(), enumerateReq)
// enumerateResp, err := bc.EnumerateWithFilters(context.Background(), enumerateReq)
// Expect(err).To(HaveOccurred())
// Expect(enumerateResp).To(BeNil())

Expand All @@ -456,13 +456,13 @@ var _ = Describe("Cloud backup [OpenStorageCluster]", func() {
By("Creating the volume")
volID = newTestVolume(vc)

enumerateReq := &api.SdkCloudBackupEnumerateRequest{
enumerateReq := &api.SdkCloudBackupEnumerateWithFiltersRequest{
ClusterId: clusterID,
SrcVolumeId: volID,
CredentialId: "dummy-credentials",
}

enumerateResp, err := bc.Enumerate(context.Background(), enumerateReq)
enumerateResp, err := bc.EnumerateWithFilters(context.Background(), enumerateReq)
Expect(err).To(HaveOccurred())
Expect(enumerateResp).To(BeNil())

Expand All @@ -485,13 +485,13 @@ var _ = Describe("Cloud backup [OpenStorageCluster]", func() {
volID = newTestVolume(vc)

By("Doing cloudbakup enumerate")
enumerateReq := &api.SdkCloudBackupEnumerateRequest{
enumerateReq := &api.SdkCloudBackupEnumerateWithFiltersRequest{
ClusterId: clusterID,
SrcVolumeId: volID,
CredentialId: "",
}

enumerateResp, err := bc.Enumerate(context.Background(), enumerateReq)
enumerateResp, err := bc.EnumerateWithFilters(context.Background(), enumerateReq)
Expect(err).To(HaveOccurred())
Expect(enumerateResp).To(BeNil())

Expand Down

0 comments on commit ee0bc48

Please sign in to comment.