File tree Expand file tree Collapse file tree 1 file changed +10
-1
lines changed
data-pipeline/src/trace_exporter Expand file tree Collapse file tree 1 file changed +10
-1
lines changed Original file line number Diff line number Diff line change @@ -1279,6 +1279,15 @@ mod tests {
1279
1279
1280
1280
exporter. shutdown ( None ) . unwrap ( ) ;
1281
1281
1282
+ // Wait for the mock server to process the stats
1283
+ for _ in 0 ..10 {
1284
+ if mock_traces. hits ( ) > 0 && mock_stats. hits ( ) > 0 {
1285
+ break ;
1286
+ } else {
1287
+ std:: thread:: sleep ( Duration :: from_millis ( 100 ) ) ;
1288
+ }
1289
+ }
1290
+
1282
1291
mock_traces. assert ( ) ;
1283
1292
mock_stats. assert ( ) ;
1284
1293
}
@@ -1352,7 +1361,7 @@ mod tests {
1352
1361
exporter. send ( data. as_ref ( ) , 1 ) . unwrap ( ) ;
1353
1362
1354
1363
exporter
1355
- . shutdown ( Some ( Duration :: from_millis ( 500 ) ) )
1364
+ . shutdown ( Some ( Duration :: from_millis ( 5 ) ) )
1356
1365
. unwrap_err ( ) ; // The shutdown should timeout
1357
1366
1358
1367
mock_traces. assert ( ) ;
You can’t perform that action at this time.
0 commit comments