Don't autosave unmodified buffers (#32626)
Closes https://github.com/zed-industries/zed/issues/12091 Proper redo of https://github.com/zed-industries/zed/pull/32603 Release Notes: - Fixed formatting effects not triggered when saving unmodified singleton buffers --------- Co-authored-by: Max Brunsfeld <maxbrunsfeld@gmail.com> Co-authored-by: Cole Miller <m@cole-miller.net>
This commit is contained in:
parent
cd018da1ad
commit
cef0c415f6
17 changed files with 453 additions and 171 deletions
|
@ -1764,6 +1764,7 @@ mod tests {
|
|||
use workspace::{
|
||||
NewFile, OpenOptions, OpenVisible, SERIALIZATION_THROTTLE_TIME, SaveIntent, SplitDirection,
|
||||
WorkspaceHandle,
|
||||
item::SaveOptions,
|
||||
item::{Item, ItemHandle},
|
||||
open_new, open_paths, pane,
|
||||
};
|
||||
|
@ -3356,7 +3357,15 @@ mod tests {
|
|||
editor.newline(&Default::default(), window, cx);
|
||||
editor.move_down(&Default::default(), window, cx);
|
||||
editor.move_down(&Default::default(), window, cx);
|
||||
editor.save(true, project.clone(), window, cx)
|
||||
editor.save(
|
||||
SaveOptions {
|
||||
format: true,
|
||||
autosave: false,
|
||||
},
|
||||
project.clone(),
|
||||
window,
|
||||
cx,
|
||||
)
|
||||
})
|
||||
})
|
||||
.unwrap()
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue