Rearrange git tests in worktree

Add support for renaming work directories
This commit is contained in:
Mikayla Maki 2023-05-19 16:23:21 -07:00
parent 623a177fe6
commit c795c9b844
No known key found for this signature in database
3 changed files with 503 additions and 412 deletions

View file

@ -42,7 +42,6 @@ use language::{
};
use project::ProjectPath;
use smallvec::SmallVec;
use text::Point;
use std::{
borrow::Cow,
cmp::{self, Ordering},
@ -51,6 +50,7 @@ use std::{
ops::Range,
sync::Arc,
};
use text::Point;
use workspace::{item::Item, GitGutterSetting, WorkspaceSettings};
enum FoldMarkers {}
@ -1059,8 +1059,10 @@ impl EditorElement {
.buffer_snapshot
.git_diff_hunks_in_range(0..(max_row.floor() as u32), false)
{
let start_display = Point::new(hunk.buffer_range.start, 0).to_display_point(&layout.position_map.snapshot.display_snapshot);
let end_display = Point::new(hunk.buffer_range.end, 0).to_display_point(&layout.position_map.snapshot.display_snapshot);
let start_display = Point::new(hunk.buffer_range.start, 0)
.to_display_point(&layout.position_map.snapshot.display_snapshot);
let end_display = Point::new(hunk.buffer_range.end, 0)
.to_display_point(&layout.position_map.snapshot.display_snapshot);
let start_y = y_for_row(start_display.row() as f32);
let mut end_y = if hunk.buffer_range.start == hunk.buffer_range.end {
y_for_row((end_display.row() + 1) as f32)