Unify the tasks modal and the new session modal (#31646)

Release Notes:

- Debugger Beta: added a button to the quick action bar to start a debug
session or spawn a task, depending on which of these actions was taken
most recently.
- Debugger Beta: incorporated the tasks modal into the new session modal
as an additional tab.

---------

Co-authored-by: Julia Ryan <juliaryan3.14@gmail.com>
Co-authored-by: Julia Ryan <p1n3appl3@users.noreply.github.com>
Co-authored-by: Anthony Eid <hello@anthonyeid.me>
Co-authored-by: Mikayla <mikayla@zed.dev>
This commit is contained in:
Cole Miller
2025-05-29 21:33:52 -04:00
committed by GitHub
co-authored by Julia Ryan Julia Ryan Anthony Eid Mikayla
parent 804de3316e
commit 1445af559b
12 changed files with 434 additions and 224 deletions
@@ -7,6 +7,7 @@ use std::sync::atomic::{AtomicBool, Ordering};
use task::{DebugRequest, DebugScenario, LaunchRequest, TaskContext, VariableName, ZedDebugConfig};
use util::path;
use crate::new_session_modal::NewSessionMode;
use crate::tests::{init_test, init_test_workspace};
#[gpui::test]
@@ -170,7 +171,13 @@ async fn test_save_debug_scenario_to_file(executor: BackgroundExecutor, cx: &mut
workspace
.update(cx, |workspace, window, cx| {
crate::new_session_modal::NewSessionModal::show(workspace, window, cx);
crate::new_session_modal::NewSessionModal::show(
workspace,
window,
NewSessionMode::Launch,
None,
cx,
);
})
.unwrap();
@@ -184,7 +191,7 @@ async fn test_save_debug_scenario_to_file(executor: BackgroundExecutor, cx: &mut
.expect("Modal should be active");
modal.update_in(cx, |modal, window, cx| {
modal.set_custom("/project/main", "/project", false, window, cx);
modal.set_configure("/project/main", "/project", false, window, cx);
modal.save_scenario(window, cx);
});
@@ -213,7 +220,7 @@ async fn test_save_debug_scenario_to_file(executor: BackgroundExecutor, cx: &mut
pretty_assertions::assert_eq!(expected_content, actual_lines);
modal.update_in(cx, |modal, window, cx| {
modal.set_custom("/project/other", "/project", true, window, cx);
modal.set_configure("/project/other", "/project", true, window, cx);
modal.save_scenario(window, cx);
});