Skip to content

Commit

Permalink
Fix linting errors
Browse files Browse the repository at this point in the history
  • Loading branch information
muralov committed Dec 18, 2023
1 parent 790e6ef commit c7e1ec3
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
4 changes: 2 additions & 2 deletions internal/controller/operator/eventing/eventmesh.go
Original file line number Diff line number Diff line change
Expand Up @@ -50,13 +50,13 @@ func (r *Reconciler) reconcileEventMeshSubManager(ctx context.Context, eventing
// gets oauth2ClientID and secret and stops the EventMesh subscription manager if changed
err := r.syncOauth2ClientIDAndSecret(ctx, eventing)
if err != nil {
return fmt.Errorf("failed to sync OAuth secret: %v", err)
return fmt.Errorf("failed to sync OAuth secret: %w", err)
}

// CreateOrUpdate deployment for publisher proxy secret
secretForPublisher, err := r.SyncPublisherProxySecret(ctx, eventMeshSecret)
if err != nil {
return fmt.Errorf("failed to sync Publisher Proxy secret: %v", err)
return fmt.Errorf("failed to sync Publisher Proxy secret: %w", err)
}

// Set environment with secrets for EventMesh subscription controller
Expand Down
2 changes: 1 addition & 1 deletion internal/controller/operator/eventing/eventmesh_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -97,7 +97,7 @@ func Test_reconcileEventMeshSubManager(t *testing.T) {
givenKubeClientMock: func() k8s.Client {
mockKubeClient := new(k8smocks.Client)
mockKubeClient.On("GetSecret", ctx, mock.Anything, mock.Anything).Return(
nil, errors.New("secret not found")).Once()
nil, fmt.Errorf("secret not found")).Once()
return mockKubeClient
},
wantError: fmt.Errorf("failed to sync OAuth secret: secret not found"),
Expand Down

0 comments on commit c7e1ec3

Please sign in to comment.