Unnamed repository; edit this file 'description' to name the repository.
Diffstat (limited to 'helix-term/tests/test/commands/movement.rs')
-rw-r--r--helix-term/tests/test/commands/movement.rs21
1 files changed, 19 insertions, 2 deletions
diff --git a/helix-term/tests/test/commands/movement.rs b/helix-term/tests/test/commands/movement.rs
index 93218be8..dd5a3bee 100644
--- a/helix-term/tests/test/commands/movement.rs
+++ b/helix-term/tests/test/commands/movement.rs
@@ -1039,15 +1039,32 @@ async fn expand_shrink_selection() -> anyhow::Result<()> {
// shrink with no expansion history defaults to first child
(
indoc! {r##"
+ #[(
+ Some(thing),
+ Some(other_thing),
+ )|]#
+ "##},
+ "<A-i>",
+ indoc! {r##"
(
#[Some(thing)|]#,
Some(other_thing),
)
"##},
- "<A-i>",
+ ),
+ // any movement cancels selection history and falls back to first child
+ (
+ indoc! {r##"
+ (
+ Some(#[thing|]#),
+ Some(#(other_thing|)#),
+ )
+
+ "##},
+ "<A-o><A-o><A-o>jkvkkk<A-i>",
indoc! {r##"
(
- #[Some|]#(thing),
+ #[|Some(thing)]#,
Some(other_thing),
)
"##},