Make LSP task cancellation discoverable (#13226)
Release Notes: - Added the ability to cancel a cargo check by clicking on the status bar item.
This commit is contained in:
parent
84a44bef8a
commit
89d2ace713
5 changed files with 144 additions and 30 deletions
|
@ -4772,7 +4772,7 @@ async fn test_references(
|
|||
// User is informed that a request is pending.
|
||||
executor.run_until_parked();
|
||||
project_b.read_with(cx_b, |project, _| {
|
||||
let status = project.language_server_statuses().next().cloned().unwrap();
|
||||
let status = project.language_server_statuses().next().unwrap().1;
|
||||
assert_eq!(status.name, "my-fake-lsp-adapter");
|
||||
assert_eq!(
|
||||
status.pending_work.values().next().unwrap().message,
|
||||
|
@ -4802,7 +4802,7 @@ async fn test_references(
|
|||
executor.run_until_parked();
|
||||
project_b.read_with(cx_b, |project, cx| {
|
||||
// User is informed that a request is no longer pending.
|
||||
let status = project.language_server_statuses().next().unwrap();
|
||||
let status = project.language_server_statuses().next().unwrap().1;
|
||||
assert!(status.pending_work.is_empty());
|
||||
|
||||
assert_eq!(references.len(), 3);
|
||||
|
@ -4830,7 +4830,7 @@ async fn test_references(
|
|||
// User is informed that a request is pending.
|
||||
executor.run_until_parked();
|
||||
project_b.read_with(cx_b, |project, _| {
|
||||
let status = project.language_server_statuses().next().cloned().unwrap();
|
||||
let status = project.language_server_statuses().next().unwrap().1;
|
||||
assert_eq!(status.name, "my-fake-lsp-adapter");
|
||||
assert_eq!(
|
||||
status.pending_work.values().next().unwrap().message,
|
||||
|
@ -4847,7 +4847,7 @@ async fn test_references(
|
|||
// User is informed that the request is no longer pending.
|
||||
executor.run_until_parked();
|
||||
project_b.read_with(cx_b, |project, _| {
|
||||
let status = project.language_server_statuses().next().unwrap();
|
||||
let status = project.language_server_statuses().next().unwrap().1;
|
||||
assert!(status.pending_work.is_empty());
|
||||
});
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue