@@ -252,13 +252,18 @@ mod tests {
252252 // Milliseconds in json may not be exactly the same as the one we get because of the test duration.
253253 // We need to have a difference not more than 49ms to keep the same 1 first milliseconds digits.
254254 let delta = 49 ;
255+ // TODO: to remove, it-s just to investigation on CI.
256+ let error_message = format ! (
257+ "\n - milliseconds_left:{milliseconds_left}\n - milliseconds_elapsed:{milliseconds_elapsed}\n - json_string:{json_string}"
258+ ) ;
255259
256260 assert ! (
257261 ( ( expected_milliseconds_left - delta) ..=( expected_milliseconds_left + delta) )
258262 . contains( & milliseconds_left) ,
259- "milliseconds_left should be close to {} but it's {}" ,
263+ "milliseconds_left should be close to {} but it's {}. {} " ,
260264 & expected_milliseconds_left,
261- & milliseconds_left
265+ & milliseconds_left,
266+ & error_message
262267 ) ;
263268 assert ! (
264269 json_string. contains( r#""seconds_left": 0.4"# ) , // Should be close to 0.450
@@ -269,9 +274,10 @@ mod tests {
269274 assert ! (
270275 ( ( expected_milliseconds_elapsed - delta) ..=( expected_milliseconds_elapsed + delta) )
271276 . contains( & milliseconds_elapsed) ,
272- "milliseconds_elapsed should be close to {} but it's {}" ,
277+ "milliseconds_elapsed should be close to {} but it's {}. {} " ,
273278 & expected_milliseconds_elapsed,
274- & milliseconds_elapsed
279+ & milliseconds_elapsed,
280+ & error_message
275281 ) ;
276282 assert ! (
277283 json_string. contains( r#""seconds_elapsed": 0.1"# ) , // Should be close to 0.150
0 commit comments