Skip to content

Commit

Permalink
Fix flaky test (#1623)
Browse files Browse the repository at this point in the history
  • Loading branch information
trask authored Dec 24, 2024
1 parent b600c74 commit 0d77587
Showing 1 changed file with 3 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -243,9 +243,11 @@ void exportSpansToMultipleServices() {

@Test
void ignoresNullSpans() {
SpanExporter mockSpanExporter = mock(SpanExporter.class);
when(mockSpanExporter.shutdown()).thenReturn(CompletableResultCode.ofSuccess());
SpanProcessor processor =
ConsistentReservoirSamplingSpanProcessor.create(
mock(SpanExporter.class), RESERVOIR_SIZE, EXPORT_PERIOD_100_MILLIS_AS_NANOS);
mockSpanExporter, RESERVOIR_SIZE, EXPORT_PERIOD_100_MILLIS_AS_NANOS);
assertThatCode(
() -> {
processor.onStart(null, null);
Expand Down

0 comments on commit 0d77587

Please sign in to comment.