Repository: helix-editor/helix
File: helix-term/tests/test/commands/movement.rs (Rust)

Code before:
                        Some#[(|]#bar) => bar,
                        None => 42,
                    } 
                }
            "##},
        ),
        // gracefully handle multiple sibling brackets (usally for errors/incomplete syntax trees)
        // in the past we selected the first > instead of the second > here
        (
            indoc! {r##"
                fn foo() {
                    foo::<b#[a|]#r<>> 
                }
            "##},
            "mm",
            indoc! {r##"
                fn foo() {
                    foo::<bar<>#[>|]# 
                }
            "##},
        ),
    ];

    let python_tests = vec![
        // python quotes have a slightly more complex syntax tree
        // that tirggerd a bug in an old implementation so we test
        // them here
        (
            indoc! {r##"
                foo_python = "mm does not#[ |]#work on this string"
            "##},
            "mm",
            indoc! {r##"
                foo_python = "mm does not work on this string#["|]#
            "##},
        ),
        (
            indoc! {r##"
                foo_python = "mm does not#[ |]#work on this string"
            "##},
            "mmmm",
            indoc! {r##"
                foo_python = #["|]#mm does not work on this string"
            "##},
        ),
    ];

    for test in rust_tests {
        println!("{test:?}");
        test_with_config(AppBuilder::new().with_file("foo.rs", None), test).await?;
    }

Review comment (bug):
```suggestion
        // that triggerd a bug in an old implementation so we test
```

Code after:
                        Some#[(|]#bar) => bar,
                        None => 42,
                    } 
                }
            "##},
        ),
        // gracefully handle multiple sibling brackets (usally for errors/incomplete syntax trees)
        // in the past we selected the first > instead of the second > here
        (
            indoc! {r##"
                fn foo() {
                    foo::<b#[a|]#r<>> 
                }
            "##},
            "mm",
            indoc! {r##"
                fn foo() {
                    foo::<bar<>#[>|]# 
                }
            "##},
        ),
    ];

    let python_tests = vec![
        // python quotes have a slightly more complex syntax tree
        // that triggerd a bug in an old implementation so we test
        // them here
        (
            indoc! {r##"
                foo_python = "mm does not#[ |]#work on this string"
            "##},
            "mm",
            indoc! {r##"
                foo_python = "mm does not work on this string#["|]#
            "##},
        ),
        (
            indoc! {r##"
                foo_python = "mm does not#[ |]#work on this string"
            "##},
            "mmmm",
            indoc! {r##"
                foo_python = #["|]#mm does not work on this string"
            "##},
        ),
    ];

    for test in rust_tests {
        println!("{test:?}");
        test_with_config(AppBuilder::new().with_file("foo.rs", None), test).await?;
    }