Skip to content

Commit 516250d

Browse files
author
Ariel Kass
committed
resolving wsl_v5 issues
Signed-off-by: Ariel Kass <[email protected]>
1 parent d54780d commit 516250d

File tree

7 files changed

+12
-0
lines changed

7 files changed

+12
-0
lines changed

controllers/secret.go

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -29,6 +29,7 @@ import (
2929
func (r *VolumeReplicationReconciler) getSecret(ctx context.Context, logger logr.Logger, name, namespace string) (map[string]string, error) {
3030
namespacedName := types.NamespacedName{Name: name, Namespace: namespace}
3131
secret := &corev1.Secret{}
32+
3233
err := r.Get(ctx, namespacedName, secret)
3334
if err != nil {
3435
if apierrors.IsNotFound(err) {

controllers/suite_test.go

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -74,6 +74,7 @@ var _ = ginkgo.BeforeSuite(func() {
7474

7575
var _ = ginkgo.AfterSuite(func() {
7676
ginkgo.By("tearing down the test environment")
77+
7778
err := testEnv.Stop()
7879
gomega.Expect(err).NotTo(gomega.HaveOccurred())
7980
})

controllers/vg.go

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -32,6 +32,7 @@ func (r VolumeReplicationReconciler) getVGDataSource(ctx context.Context, logger
3232
*volumegroupv1.VolumeGroup, *volumegroupv1.VolumeGroupContent, error,
3333
) {
3434
vg := &volumegroupv1.VolumeGroup{}
35+
3536
err := r.Get(ctx, req, vg)
3637
if err != nil {
3738
if errors.IsNotFound(err) {
@@ -44,6 +45,7 @@ func (r VolumeReplicationReconciler) getVGDataSource(ctx context.Context, logger
4445
vgc := &volumegroupv1.VolumeGroupContent{}
4546
volumeGroupContentName := *vg.Spec.Source.VolumeGroupContentName
4647
namespacedVGC := types.NamespacedName{Name: volumeGroupContentName, Namespace: vg.Namespace}
48+
4749
err = r.Get(ctx, namespacedVGC, vgc)
4850
if err != nil {
4951
if errors.IsNotFound(err) {

controllers/volumereplication_controller.go

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -82,6 +82,7 @@ func (r *VolumeReplicationReconciler) Reconcile(ctx context.Context, req ctrl.Re
8282

8383
// Fetch VolumeReplication instance
8484
instance := &replicationv1alpha1.VolumeReplication{}
85+
8586
err := r.Get(ctx, req.NamespacedName, instance)
8687
if err != nil {
8788
if errors.IsNotFound(err) {

controllers/volumereplicationclass.go

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -31,6 +31,7 @@ import (
3131
//nolint:gocritic
3232
func (r VolumeReplicationReconciler) getVolumeReplicationClass(ctx context.Context, logger logr.Logger, vrcName string) (*replicationv1alpha1.VolumeReplicationClass, error) {
3333
vrcObj := &replicationv1alpha1.VolumeReplicationClass{}
34+
3435
err := r.Get(ctx, types.NamespacedName{Name: vrcName}, vrcObj)
3536
if err != nil {
3637
if errors.IsNotFound(err) {

controllers/volumereplicationclass_test.go

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -63,6 +63,7 @@ func TestGetVolumeReplicaClass(t *testing.T) {
6363
}
6464

6565
reconciler := createFakeVolumeReplicationReconciler(t, objects...)
66+
6667
vrcObj, err := reconciler.getVolumeReplicationClass(context.TODO(), reconciler.Log, mockVolumeReplicationClassObj.Name)
6768

6869
if tc.errorExpected {

pkg/client/replication-client_test.go

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -35,6 +35,7 @@ func TestEnableVolumeReplication(t *testing.T) {
3535
},
3636
}
3737
client := mockedEnableReplication
38+
3839
resp, err := client.EnableVolumeReplication("", "", nil, nil)
3940
require.Equal(t, &replicationlib.EnableVolumeReplicationResponse{}, resp)
4041
require.NoError(t, err)
@@ -60,6 +61,7 @@ func TestDisableVolumeReplication(t *testing.T) {
6061
},
6162
}
6263
client := mockedDisableReplication
64+
6365
resp, err := client.DisableVolumeReplication("", "", nil, nil)
6466
require.Equal(t, &replicationlib.DisableVolumeReplicationResponse{}, resp)
6567
require.NoError(t, err)
@@ -85,6 +87,7 @@ func TestPromoteVolume(t *testing.T) {
8587
},
8688
}
8789
client := mockedPromoteVolume
90+
8891
resp, err := client.PromoteVolume("", "", false, nil, nil)
8992
require.Equal(t, &replicationlib.PromoteVolumeResponse{}, resp)
9093
require.NoError(t, err)
@@ -110,6 +113,7 @@ func TestDemoteVolume(t *testing.T) {
110113
},
111114
}
112115
client := mockedDemoteVolume
116+
113117
resp, err := client.DemoteVolume("", "", nil, nil)
114118
require.Equal(t, &replicationlib.DemoteVolumeResponse{}, resp)
115119
require.NoError(t, err)
@@ -135,6 +139,7 @@ func TestResyncVolume(t *testing.T) {
135139
},
136140
}
137141
client := mockedResyncVolume
142+
138143
resp, err := client.ResyncVolume("", "", nil, nil)
139144
require.Equal(t, &replicationlib.ResyncVolumeResponse{}, resp)
140145
require.NoError(t, err)

0 commit comments

Comments
 (0)