Fix a test flake involving zeroed out group_intervals (#20328)
Release Notes: - N/A
This commit is contained in:
parent
454c9dc06d
commit
de70852497
4 changed files with 22 additions and 7 deletions
|
@ -169,8 +169,12 @@ fn test_undo_redo_with_selection_restoration(cx: &mut TestAppContext) {
|
|||
init_test(cx, |_| {});
|
||||
|
||||
let mut now = Instant::now();
|
||||
let buffer = cx.new_model(|cx| language::Buffer::local("123456", cx));
|
||||
let group_interval = buffer.update(cx, |buffer, _| buffer.transaction_group_interval());
|
||||
let group_interval = Duration::from_millis(1);
|
||||
let buffer = cx.new_model(|cx| {
|
||||
let mut buf = language::Buffer::local("123456", cx);
|
||||
buf.set_group_interval(group_interval);
|
||||
buf
|
||||
});
|
||||
let buffer = cx.new_model(|cx| MultiBuffer::singleton(buffer, cx));
|
||||
let editor = cx.add_window(|cx| build_editor(buffer.clone(), cx));
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue