diff --git a/helix-term/tests/test/commands.rs b/helix-term/tests/test/commands.rs index 3330eb597..537bc4827 100644 --- a/helix-term/tests/test/commands.rs +++ b/helix-term/tests/test/commands.rs @@ -910,6 +910,64 @@ async fn test_injected_comment_tokens_multiple_selections() -> anyhow::Result<() )) .await?; + // Many single-selections + test(( + indoc! {r#"\ +

C#[|o]#mment t#(|o)#ggle #(|o)#n this line sh#(|o)#uld use the HTML c#(|o)#mment t#(|o)#ken(s).

+ + "#}, + ":lang html C", + indoc! {r#"\ +

C#[|]#mment t#(|)#ggle #(|)#n this line sh#(|)#uld use the HTML c#(|)#mment t#(|)#ken(s).

+ + "#}, + )) + .await?; + test(( + indoc! {r#"\ +

C#[|]#mment t#(|)#ggle #(|)#n this line sh#(|)#uld use the HTML c#(|)#mment t#(|)#ken(s).

+ + "#}, + ":lang html C", + indoc! {r#"\ +

C#[|o]#mment t#(|o)#ggle #(|o)#n this line sh#(|o)#uld use the HTML c#(|o)#mment t#(|o)#ken(s).

+ + "#}, + )) + .await?; + Ok(()) }