Skip to content

Commit

Permalink
Fix failing unittest - 5
Browse files Browse the repository at this point in the history
  • Loading branch information
aditya1702 committed Nov 15, 2024
1 parent 86c2f1e commit ff6a81a
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions internal/services/ingest_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -328,8 +328,8 @@ func TestTrackRPCServiceHealth(t *testing.T) {
defer cancel()

// Mock both expected warning messages
mockAppTracker.On("CaptureMessage", "ingestion service stale for over 1m0s").Maybe()
mockAppTracker.On("CaptureMessage", "rpc service unhealthy for over 1m0s").Once()
mockAppTracker.On("CaptureMessage", "ingestion service stale for over 1m0s").Maybe().Return(nil)
mockAppTracker.On("CaptureMessage", "rpc service unhealthy for over 1m0s").Once().Return(nil)

// Set up RPC health check to consistently return error
mockRPCService.On("GetHealth").Return(entities.RPCGetHealthResult{}, errors.New("rpc error"))
Expand Down

0 comments on commit ff6a81a

Please sign in to comment.