Skip to content

Commit

Permalink
Temp fix flaky test for BatchSpanprocessors (open-telemetry#2671)
Browse files Browse the repository at this point in the history
  • Loading branch information
cijothomas committed Feb 18, 2025
1 parent 175cb13 commit d3adabf
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions opentelemetry-sdk/src/trace/span_processor.rs
Original file line number Diff line number Diff line change
Expand Up @@ -1268,7 +1268,7 @@ mod tests {
processor.on_end(span);
}

tokio::time::sleep(Duration::from_millis(200)).await;
tokio::time::sleep(Duration::from_millis(1000)).await;

let exported_spans = exporter_shared.lock().unwrap();
assert_eq!(exported_spans.len(), 4);
Expand All @@ -1292,7 +1292,7 @@ mod tests {
processor.on_end(span);
}

tokio::time::sleep(Duration::from_millis(200)).await;
tokio::time::sleep(Duration::from_millis(1000)).await;

let exported_spans = exporter_shared.lock().unwrap();
assert_eq!(exported_spans.len(), 4);
Expand Down Expand Up @@ -1327,7 +1327,7 @@ mod tests {
}

// Allow time for batching and export
tokio::time::sleep(Duration::from_millis(200)).await;
tokio::time::sleep(Duration::from_millis(1000)).await;

// Verify exported spans
let exported_spans = exporter_shared.lock().unwrap();
Expand Down

0 comments on commit d3adabf

Please sign in to comment.