aboutsummaryrefslogtreecommitdiff
path: root/src/client/shell/tests
diff options
context:
space:
mode:
authorCan Celik <ogulcancelik@gmail.com>2026-09-19 14:47:18 +0300
committerGitHub <noreply@github.com>2026-09-19 14:47:18 +0300
commitcc7c696cd0772e466da403eb4e3f00f4e8d8ae1e (patch)
treed8325f7f2fb1ac53613ae56e8215042e6d497dd9 /src/client/shell/tests
parent3f2a6e743f67bc947cfa06be25df106d00b9ee11 (diff)
feat: add configurable pane screen and scrollback clearing (#4383)
Diffstat (limited to 'src/client/shell/tests')
-rw-r--r--src/client/shell/tests/popup_focus_projection.rs19
1 files changed, 19 insertions, 0 deletions
diff --git a/src/client/shell/tests/popup_focus_projection.rs b/src/client/shell/tests/popup_focus_projection.rs
index 25d3b334..7f3ea137 100644
--- a/src/client/shell/tests/popup_focus_projection.rs
+++ b/src/client/shell/tests/popup_focus_projection.rs
@@ -885,6 +885,25 @@ fn pane_scrollbar_track_and_thumb_use_stable_endpoint_scroll_requests() {
}
#[test]
+fn clear_pane_binding_targets_the_focused_endpoint_pane() {
+ let mut state = ClientShellState::new(ClientShellConfig::from_config(&Config::default()));
+ state.set_snapshot(Box::new(snapshot()));
+ state.set_pane_surface(surface());
+ let mut input = ClientShellInput::default();
+ state.record_binding(
+ crate::input::KeybindMatch::Action(crate::input::KeybindAction::ClearPane),
+ &mut input,
+ );
+ assert!(input.requests.is_empty());
+ assert!(matches!(
+ &input.actions[..],
+ [ClientShellAction::Endpoint { request, .. }]
+ if matches!(&request.method, crate::api::schema::Method::PaneClear(target)
+ if target.pane_id == "pane_1")
+ ));
+}
+
+#[test]
fn edit_scrollback_binding_targets_the_focused_endpoint_pane() {
let mut state = ClientShellState::new(ClientShellConfig::from_config(&Config::default()));
state.set_snapshot(Box::new(snapshot()));