aboutsummaryrefslogtreecommitdiff
path: root/crates/ra_hir/src/ty/tests.rs
diff options
context:
space:
mode:
Diffstat (limited to 'crates/ra_hir/src/ty/tests.rs')
-rw-r--r--crates/ra_hir/src/ty/tests.rs6
1 files changed, 3 insertions, 3 deletions
diff --git a/crates/ra_hir/src/ty/tests.rs b/crates/ra_hir/src/ty/tests.rs
index b44ac9987..929fee04c 100644
--- a/crates/ra_hir/src/ty/tests.rs
+++ b/crates/ra_hir/src/ty/tests.rs
@@ -321,7 +321,7 @@ fn infer(content: &str) -> String {
321 .filter_map(ast::FnDef::cast) 321 .filter_map(ast::FnDef::cast)
322 { 322 {
323 let func = source_binder::function_from_source(&db, file_id, fn_def).unwrap(); 323 let func = source_binder::function_from_source(&db, file_id, fn_def).unwrap();
324 let inference_result = func.infer(&db).unwrap(); 324 let inference_result = func.infer(&db);
325 let body_syntax_mapping = func.body_syntax_mapping(&db); 325 let body_syntax_mapping = func.body_syntax_mapping(&db);
326 let mut types = Vec::new(); 326 let mut types = Vec::new();
327 for (pat, ty) in inference_result.type_of_pat.iter() { 327 for (pat, ty) in inference_result.type_of_pat.iter() {
@@ -405,7 +405,7 @@ fn typing_whitespace_inside_a_function_should_not_invalidate_types() {
405 let func = source_binder::function_from_position(&db, pos).unwrap(); 405 let func = source_binder::function_from_position(&db, pos).unwrap();
406 { 406 {
407 let events = db.log_executed(|| { 407 let events = db.log_executed(|| {
408 func.infer(&db).unwrap(); 408 func.infer(&db);
409 }); 409 });
410 assert!(format!("{:?}", events).contains("infer")) 410 assert!(format!("{:?}", events).contains("infer"))
411 } 411 }
@@ -424,7 +424,7 @@ fn typing_whitespace_inside_a_function_should_not_invalidate_types() {
424 424
425 { 425 {
426 let events = db.log_executed(|| { 426 let events = db.log_executed(|| {
427 func.infer(&db).unwrap(); 427 func.infer(&db);
428 }); 428 });
429 assert!(!format!("{:?}", events).contains("infer"), "{:#?}", events) 429 assert!(!format!("{:?}", events).contains("infer"), "{:#?}", events)
430 } 430 }