File tree Expand file tree Collapse file tree 1 file changed +12
-11
lines changed Expand file tree Collapse file tree 1 file changed +12
-11
lines changed Original file line number Diff line number Diff line change @@ -577,23 +577,24 @@ mod tests {
577577 flags,
578578 } ;
579579 let update_time = Instant :: now ( ) ;
580- sleep ( Duration :: from_millis ( DELAY_BUFFER_MS ) ) ;
581580 status_bar. handle_ins_status ( msg) ;
582- let last_ins_status_receipt_time = {
583- let shared_data = status_bar
584- . heartbeat_data
585- . lock ( )
586- . expect ( HEARTBEAT_LOCK_MUTEX_FAILURE ) ;
587- ( * shared_data) . last_ins_status_receipt_time
588- } ;
589- assert ! ( last_ins_status_receipt_time. unwrap( ) > update_time) ;
590- let ins_status_flags = {
581+ sleep ( Duration :: from_millis ( DELAY_BUFFER_MS ) ) ;
582+ let ( last_ins_status_receipt_time, ins_status_flags) = {
591583 let shared_data = status_bar
592584 . heartbeat_data
593585 . lock ( )
594586 . expect ( HEARTBEAT_LOCK_MUTEX_FAILURE ) ;
595- ( * shared_data) . ins_status_flags
587+ (
588+ ( * shared_data) . last_ins_status_receipt_time ,
589+ ( * shared_data) . ins_status_flags ,
590+ )
596591 } ;
592+ assert ! (
593+ last_ins_status_receipt_time. unwrap( ) > update_time,
594+ "[Flaky] If this test fails
595+ consider rerunning as it is known to be flaky.
596+ More info found here: https://swift-nav.atlassian.net/browse/CPP-252"
597+ ) ;
597598 assert_eq ! ( ins_status_flags, flags) ;
598599 }
599600
You can’t perform that action at this time.
0 commit comments