newFakeTelemetryReporter creates a new fakeTelemetryReporter with a buffered channel. The buffer size determines how many snapshots can be reported before blocking.
(ctx context.Context, t testing.TB, bufferSize int)
| 3294 | // newFakeTelemetryReporter creates a new fakeTelemetryReporter with a buffered channel. |
| 3295 | // The buffer size determines how many snapshots can be reported before blocking. |
| 3296 | func newFakeTelemetryReporter(ctx context.Context, t testing.TB, bufferSize int) *fakeTelemetryReporter { |
| 3297 | return &fakeTelemetryReporter{ |
| 3298 | enabled: true, |
| 3299 | snapshots: make(chan *telemetry.Snapshot, bufferSize), |
| 3300 | ctx: ctx, |
| 3301 | t: t, |
| 3302 | } |
| 3303 | } |
| 3304 | |
| 3305 | // Report implements the telemetry.Reporter interface by sending the snapshot |
| 3306 | // to the snapshots channel. |
no outgoing calls
no test coverage detected