feat: separate draft pull requests into their own tab
This commit is contained in:
+10
-1
@@ -3508,7 +3508,11 @@ fn pull_request_picker_renders_all_rows_without_a_pinned_offset() {
|
||||
},
|
||||
label: format!("#{index:02} Pull request"),
|
||||
description: "open · main ← topic".into(),
|
||||
category: Category::Open,
|
||||
category: if index == 1 {
|
||||
Category::Drafts
|
||||
} else {
|
||||
Category::Open
|
||||
},
|
||||
},
|
||||
format!("2026-01-{:02}T00:00:00Z", 20 - index),
|
||||
)
|
||||
@@ -3548,6 +3552,11 @@ fn pull_request_picker_renders_all_rows_without_a_pinned_offset() {
|
||||
);
|
||||
render_diff(&mut terminal, &diff, &mut panels);
|
||||
assert!(screen_text(&terminal).contains("No matching pull requests"));
|
||||
diff.handle(Input::Char('\t'));
|
||||
render_diff(&mut terminal, &diff, &mut panels);
|
||||
let text = screen_text(&terminal);
|
||||
assert!(text.contains("> #01 Pull request"));
|
||||
assert!(!text.contains("#00 Pull request") && !text.contains("#19 Pull request"));
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user