File tree Expand file tree Collapse file tree 1 file changed +3
-3
lines changed
core/src/loader/builtins/file_loaders Expand file tree Collapse file tree 1 file changed +3
-3
lines changed Original file line number Diff line number Diff line change @@ -308,7 +308,7 @@ mod tests {
308308 assert_eq ! ( doc. data, "initial" ) ;
309309 }
310310
311- #[ tokio:: test]
311+ #[ tokio:: test( flavor = "multi_thread" , worker_threads = 2 ) ]
312312 async fn test_non_matching_files_ignored ( ) {
313313 let temp_dir = tempfile:: tempdir ( ) . unwrap ( ) ;
314314 let matching_path = temp_dir. path ( ) . join ( "test.txt" ) ;
@@ -325,10 +325,10 @@ mod tests {
325325 let loader = builder. build ( ) ;
326326
327327 let mut receiver = loader. subscribe ( ) . await ;
328- receiver. recv ( ) . await . unwrap ( ) ;
328+ assert ! ( receiver. recv( ) . await . is_ok ( ) ) ;
329329
330330 std:: fs:: write ( & non_matching_path, "modified" ) . unwrap ( ) ;
331- tokio:: time:: sleep ( Duration :: from_secs ( 1 ) ) . await ;
331+ tokio:: time:: sleep ( tokio :: time :: Duration :: from_secs ( 1 ) ) . await ;
332332
333333 assert ! ( receiver. try_recv( ) . is_err( ) ) ;
334334 }
You can’t perform that action at this time.
0 commit comments