diff --git a/crates/collab/src/tests.rs b/crates/collab/src/tests.rs index 8949b60993..80df0ed6df 100644 --- a/crates/collab/src/tests.rs +++ b/crates/collab/src/tests.rs @@ -197,8 +197,8 @@ impl TestServer { fs: fs.clone(), build_window_options: |_, _, _| Default::default(), initialize_workspace: |_, _, _| unimplemented!(), - dock_default_item_factory: |_, _| unimplemented!(), - background_actions: || unimplemented!(), + dock_default_item_factory: |_, _| None, + background_actions: || &[], }); Project::init(&client); diff --git a/crates/editor/src/editor_tests.rs b/crates/editor/src/editor_tests.rs index 0176a1e01b..d73c3c87db 100644 --- a/crates/editor/src/editor_tests.rs +++ b/crates/editor/src/editor_tests.rs @@ -484,9 +484,7 @@ fn test_navigation_history(cx: &mut gpui::MutableAppContext) { cx.set_global(Settings::test(cx)); cx.set_global(DragAndDrop::::default()); use workspace::item::Item; - let (_, pane) = cx.add_window(Default::default(), |cx| { - Pane::new(0, None, || unimplemented!(), cx) - }); + let (_, pane) = cx.add_window(Default::default(), |cx| Pane::new(0, None, || &[], cx)); let buffer = MultiBuffer::build_simple(&sample_text(300, 5, 'a'), cx); cx.add_view(&pane, |cx| { @@ -2356,10 +2354,10 @@ async fn test_clipboard(cx: &mut gpui::TestAppContext) { e.handle_input(") ", cx); }); cx.assert_editor_state(indoc! {" - ( one✅ - three - five ) ˇtwo one✅ four three six five ( one✅ - three + ( one✅ + three + five ) ˇtwo one✅ four three six five ( one✅ + three five ) ˇ"}); // Cut with three selections, one of which is full-line. @@ -5564,7 +5562,7 @@ async fn test_following_with_multiple_excerpts(cx: &mut gpui::TestAppContext) { Settings::test_async(cx); let fs = FakeFs::new(cx.background()); let project = Project::test(fs, ["/file.rs".as_ref()], cx).await; - let (_, pane) = cx.add_window(|cx| Pane::new(0, None, || unimplemented!(), cx)); + let (_, pane) = cx.add_window(|cx| Pane::new(0, None, || &[], cx)); let leader = pane.update(cx, |_, cx| { let multibuffer = cx.add_model(|_| MultiBuffer::new(0)); diff --git a/crates/workspace/src/dock.rs b/crates/workspace/src/dock.rs index efba568b90..fd7638c5fb 100644 --- a/crates/workspace/src/dock.rs +++ b/crates/workspace/src/dock.rs @@ -500,7 +500,7 @@ mod tests { 0, project.clone(), default_item_factory, - || unimplemented!(), + || &[], cx, ) }); @@ -634,7 +634,7 @@ mod tests { 0, project, default_item_factory, - || unimplemented!(), + || &[], cx, ) }); diff --git a/crates/workspace/src/workspace.rs b/crates/workspace/src/workspace.rs index 40053b103a..ef14bfa2fe 100644 --- a/crates/workspace/src/workspace.rs +++ b/crates/workspace/src/workspace.rs @@ -455,8 +455,8 @@ impl AppState { user_store, initialize_workspace: |_, _, _| {}, build_window_options: |_, _, _| Default::default(), - dock_default_item_factory: |_, _| unimplemented!(), - background_actions: || unimplemented!(), + dock_default_item_factory: |_, _| None, + background_actions: || &[], }) } } @@ -3017,8 +3017,8 @@ mod tests { Default::default(), 0, project.clone(), - |_, _| unimplemented!(), - || unimplemented!(), + |_, _| None, + || &[], cx, ) }); @@ -3090,8 +3090,8 @@ mod tests { Default::default(), 0, project.clone(), - |_, _| unimplemented!(), - || unimplemented!(), + |_, _| None, + || &[], cx, ) }); @@ -3191,8 +3191,8 @@ mod tests { Default::default(), 0, project.clone(), - |_, _| unimplemented!(), - || unimplemented!(), + |_, _| None, + || &[], cx, ) }); @@ -3231,14 +3231,7 @@ mod tests { let project = Project::test(fs, None, cx).await; let (window_id, workspace) = cx.add_window(|cx| { - Workspace::new( - Default::default(), - 0, - project, - |_, _| unimplemented!(), - || unimplemented!(), - cx, - ) + Workspace::new(Default::default(), 0, project, |_, _| None, || &[], cx) }); let item1 = cx.add_view(&workspace, |cx| { @@ -3347,14 +3340,7 @@ mod tests { let project = Project::test(fs, [], cx).await; let (window_id, workspace) = cx.add_window(|cx| { - Workspace::new( - Default::default(), - 0, - project, - |_, _| unimplemented!(), - || unimplemented!(), - cx, - ) + Workspace::new(Default::default(), 0, project, |_, _| None, || &[], cx) }); // Create several workspace items with single project entries, and two @@ -3463,14 +3449,7 @@ mod tests { let project = Project::test(fs, [], cx).await; let (window_id, workspace) = cx.add_window(|cx| { - Workspace::new( - Default::default(), - 0, - project, - |_, _| unimplemented!(), - || unimplemented!(), - cx, - ) + Workspace::new(Default::default(), 0, project, |_, _| None, || &[], cx) }); let item = cx.add_view(&workspace, |cx| { @@ -3589,14 +3568,7 @@ mod tests { let project = Project::test(fs, [], cx).await; let (_, workspace) = cx.add_window(|cx| { - Workspace::new( - Default::default(), - 0, - project, - |_, _| unimplemented!(), - || unimplemented!(), - cx, - ) + Workspace::new(Default::default(), 0, project, |_, _| None, || &[], cx) }); let item = cx.add_view(&workspace, |cx| {