@ -12,7 +12,7 @@ fn matching_pairs() -> impl Iterator<Item = &'static (char, char)> {
DEFAULT_PAIRS . iter ( ) . filter ( | ( open , close ) | open = = close )
DEFAULT_PAIRS . iter ( ) . filter ( | ( open , close ) | open = = close )
}
}
#[ tokio::test ]
#[ tokio::test (flavor = " multi_thread " ) ]
async fn insert_basic ( ) -> anyhow ::Result < ( ) > {
async fn insert_basic ( ) -> anyhow ::Result < ( ) > {
for pair in DEFAULT_PAIRS {
for pair in DEFAULT_PAIRS {
test ( (
test ( (
@ -26,7 +26,7 @@ async fn insert_basic() -> anyhow::Result<()> {
Ok ( ( ) )
Ok ( ( ) )
}
}
#[ tokio::test ]
#[ tokio::test (flavor = " multi_thread " ) ]
async fn insert_configured_multi_byte_chars ( ) -> anyhow ::Result < ( ) > {
async fn insert_configured_multi_byte_chars ( ) -> anyhow ::Result < ( ) > {
// NOTE: these are multi-byte Unicode characters
// NOTE: these are multi-byte Unicode characters
let pairs = hashmap ! ( '„' = > '“' , '‚ ' = > '‘ ' , '「' = > '」' ) ;
let pairs = hashmap ! ( '„' = > '“' , '‚ ' = > '‘ ' , '「' = > '」' ) ;
@ -68,7 +68,7 @@ async fn insert_configured_multi_byte_chars() -> anyhow::Result<()> {
Ok ( ( ) )
Ok ( ( ) )
}
}
#[ tokio::test ]
#[ tokio::test (flavor = " multi_thread " ) ]
async fn insert_after_word ( ) -> anyhow ::Result < ( ) > {
async fn insert_after_word ( ) -> anyhow ::Result < ( ) > {
for pair in differing_pairs ( ) {
for pair in differing_pairs ( ) {
test ( (
test ( (
@ -91,7 +91,7 @@ async fn insert_after_word() -> anyhow::Result<()> {
Ok ( ( ) )
Ok ( ( ) )
}
}
#[ tokio::test ]
#[ tokio::test (flavor = " multi_thread " ) ]
async fn insert_before_word ( ) -> anyhow ::Result < ( ) > {
async fn insert_before_word ( ) -> anyhow ::Result < ( ) > {
for pair in DEFAULT_PAIRS {
for pair in DEFAULT_PAIRS {
test ( (
test ( (
@ -105,7 +105,7 @@ async fn insert_before_word() -> anyhow::Result<()> {
Ok ( ( ) )
Ok ( ( ) )
}
}
#[ tokio::test ]
#[ tokio::test (flavor = " multi_thread " ) ]
async fn insert_before_word_selection ( ) -> anyhow ::Result < ( ) > {
async fn insert_before_word_selection ( ) -> anyhow ::Result < ( ) > {
for pair in DEFAULT_PAIRS {
for pair in DEFAULT_PAIRS {
test ( (
test ( (
@ -119,7 +119,7 @@ async fn insert_before_word_selection() -> anyhow::Result<()> {
Ok ( ( ) )
Ok ( ( ) )
}
}
#[ tokio::test ]
#[ tokio::test (flavor = " multi_thread " ) ]
async fn insert_before_word_selection_trailing_word ( ) -> anyhow ::Result < ( ) > {
async fn insert_before_word_selection_trailing_word ( ) -> anyhow ::Result < ( ) > {
for pair in differing_pairs ( ) {
for pair in differing_pairs ( ) {
test ( (
test ( (
@ -133,7 +133,7 @@ async fn insert_before_word_selection_trailing_word() -> anyhow::Result<()> {
Ok ( ( ) )
Ok ( ( ) )
}
}
#[ tokio::test ]
#[ tokio::test (flavor = " multi_thread " ) ]
async fn insert_closer_selection_trailing_word ( ) -> anyhow ::Result < ( ) > {
async fn insert_closer_selection_trailing_word ( ) -> anyhow ::Result < ( ) > {
for pair in differing_pairs ( ) {
for pair in differing_pairs ( ) {
test ( (
test ( (
@ -147,7 +147,7 @@ async fn insert_closer_selection_trailing_word() -> anyhow::Result<()> {
Ok ( ( ) )
Ok ( ( ) )
}
}
#[ tokio::test ]
#[ tokio::test (flavor = " multi_thread " ) ]
async fn insert_before_eol ( ) -> anyhow ::Result < ( ) > {
async fn insert_before_eol ( ) -> anyhow ::Result < ( ) > {
for pair in DEFAULT_PAIRS {
for pair in DEFAULT_PAIRS {
test ( (
test ( (
@ -166,7 +166,7 @@ async fn insert_before_eol() -> anyhow::Result<()> {
Ok ( ( ) )
Ok ( ( ) )
}
}
#[ tokio::test ]
#[ tokio::test (flavor = " multi_thread " ) ]
async fn insert_auto_pairs_disabled ( ) -> anyhow ::Result < ( ) > {
async fn insert_auto_pairs_disabled ( ) -> anyhow ::Result < ( ) > {
for pair in DEFAULT_PAIRS {
for pair in DEFAULT_PAIRS {
test_with_config (
test_with_config (
@ -191,7 +191,7 @@ async fn insert_auto_pairs_disabled() -> anyhow::Result<()> {
Ok ( ( ) )
Ok ( ( ) )
}
}
#[ tokio::test ]
#[ tokio::test (flavor = " multi_thread " ) ]
async fn insert_multi_range ( ) -> anyhow ::Result < ( ) > {
async fn insert_multi_range ( ) -> anyhow ::Result < ( ) > {
for pair in DEFAULT_PAIRS {
for pair in DEFAULT_PAIRS {
test ( (
test ( (
@ -210,7 +210,7 @@ async fn insert_multi_range() -> anyhow::Result<()> {
Ok ( ( ) )
Ok ( ( ) )
}
}
#[ tokio::test ]
#[ tokio::test (flavor = " multi_thread " ) ]
async fn insert_before_multi_code_point_graphemes ( ) -> anyhow ::Result < ( ) > {
async fn insert_before_multi_code_point_graphemes ( ) -> anyhow ::Result < ( ) > {
for pair in differing_pairs ( ) {
for pair in differing_pairs ( ) {
test ( (
test ( (
@ -223,7 +223,7 @@ async fn insert_before_multi_code_point_graphemes() -> anyhow::Result<()> {
Ok ( ( ) )
Ok ( ( ) )
}
}
#[ tokio::test ]
#[ tokio::test (flavor = " multi_thread " ) ]
async fn insert_at_end_of_document ( ) -> anyhow ::Result < ( ) > {
async fn insert_at_end_of_document ( ) -> anyhow ::Result < ( ) > {
for pair in DEFAULT_PAIRS {
for pair in DEFAULT_PAIRS {
test ( TestCase {
test ( TestCase {
@ -248,7 +248,7 @@ async fn insert_at_end_of_document() -> anyhow::Result<()> {
Ok ( ( ) )
Ok ( ( ) )
}
}
#[ tokio::test ]
#[ tokio::test (flavor = " multi_thread " ) ]
async fn insert_close_inside_pair ( ) -> anyhow ::Result < ( ) > {
async fn insert_close_inside_pair ( ) -> anyhow ::Result < ( ) > {
for pair in DEFAULT_PAIRS {
for pair in DEFAULT_PAIRS {
test ( (
test ( (
@ -272,7 +272,7 @@ async fn insert_close_inside_pair() -> anyhow::Result<()> {
Ok ( ( ) )
Ok ( ( ) )
}
}
#[ tokio::test ]
#[ tokio::test (flavor = " multi_thread " ) ]
async fn insert_close_inside_pair_multi ( ) -> anyhow ::Result < ( ) > {
async fn insert_close_inside_pair_multi ( ) -> anyhow ::Result < ( ) > {
for pair in DEFAULT_PAIRS {
for pair in DEFAULT_PAIRS {
test ( (
test ( (
@ -296,7 +296,7 @@ async fn insert_close_inside_pair_multi() -> anyhow::Result<()> {
Ok ( ( ) )
Ok ( ( ) )
}
}
#[ tokio::test ]
#[ tokio::test (flavor = " multi_thread " ) ]
async fn insert_nested_open_inside_pair ( ) -> anyhow ::Result < ( ) > {
async fn insert_nested_open_inside_pair ( ) -> anyhow ::Result < ( ) > {
for pair in differing_pairs ( ) {
for pair in differing_pairs ( ) {
test ( (
test ( (
@ -320,7 +320,7 @@ async fn insert_nested_open_inside_pair() -> anyhow::Result<()> {
Ok ( ( ) )
Ok ( ( ) )
}
}
#[ tokio::test ]
#[ tokio::test (flavor = " multi_thread " ) ]
async fn insert_nested_open_inside_pair_multi ( ) -> anyhow ::Result < ( ) > {
async fn insert_nested_open_inside_pair_multi ( ) -> anyhow ::Result < ( ) > {
for outer_pair in DEFAULT_PAIRS {
for outer_pair in DEFAULT_PAIRS {
for inner_pair in DEFAULT_PAIRS {
for inner_pair in DEFAULT_PAIRS {
@ -352,7 +352,7 @@ async fn insert_nested_open_inside_pair_multi() -> anyhow::Result<()> {
Ok ( ( ) )
Ok ( ( ) )
}
}
#[ tokio::test ]
#[ tokio::test (flavor = " multi_thread " ) ]
async fn append_basic ( ) -> anyhow ::Result < ( ) > {
async fn append_basic ( ) -> anyhow ::Result < ( ) > {
for pair in DEFAULT_PAIRS {
for pair in DEFAULT_PAIRS {
test ( (
test ( (
@ -371,7 +371,7 @@ async fn append_basic() -> anyhow::Result<()> {
Ok ( ( ) )
Ok ( ( ) )
}
}
#[ tokio::test ]
#[ tokio::test (flavor = " multi_thread " ) ]
async fn append_multi_range ( ) -> anyhow ::Result < ( ) > {
async fn append_multi_range ( ) -> anyhow ::Result < ( ) > {
for pair in DEFAULT_PAIRS {
for pair in DEFAULT_PAIRS {
test ( (
test ( (
@ -390,7 +390,7 @@ async fn append_multi_range() -> anyhow::Result<()> {
Ok ( ( ) )
Ok ( ( ) )
}
}
#[ tokio::test ]
#[ tokio::test (flavor = " multi_thread " ) ]
async fn append_close_inside_pair ( ) -> anyhow ::Result < ( ) > {
async fn append_close_inside_pair ( ) -> anyhow ::Result < ( ) > {
for pair in DEFAULT_PAIRS {
for pair in DEFAULT_PAIRS {
test ( (
test ( (
@ -414,7 +414,7 @@ async fn append_close_inside_pair() -> anyhow::Result<()> {
Ok ( ( ) )
Ok ( ( ) )
}
}
#[ tokio::test ]
#[ tokio::test (flavor = " multi_thread " ) ]
async fn append_close_inside_pair_multi ( ) -> anyhow ::Result < ( ) > {
async fn append_close_inside_pair_multi ( ) -> anyhow ::Result < ( ) > {
for pair in DEFAULT_PAIRS {
for pair in DEFAULT_PAIRS {
test ( (
test ( (
@ -438,7 +438,7 @@ async fn append_close_inside_pair_multi() -> anyhow::Result<()> {
Ok ( ( ) )
Ok ( ( ) )
}
}
#[ tokio::test ]
#[ tokio::test (flavor = " multi_thread " ) ]
async fn append_end_of_word ( ) -> anyhow ::Result < ( ) > {
async fn append_end_of_word ( ) -> anyhow ::Result < ( ) > {
for pair in differing_pairs ( ) {
for pair in differing_pairs ( ) {
test ( (
test ( (
@ -457,7 +457,7 @@ async fn append_end_of_word() -> anyhow::Result<()> {
Ok ( ( ) )
Ok ( ( ) )
}
}
#[ tokio::test ]
#[ tokio::test (flavor = " multi_thread " ) ]
async fn append_middle_of_word ( ) -> anyhow ::Result < ( ) > {
async fn append_middle_of_word ( ) -> anyhow ::Result < ( ) > {
for pair in differing_pairs ( ) {
for pair in differing_pairs ( ) {
test ( (
test ( (
@ -471,7 +471,7 @@ async fn append_middle_of_word() -> anyhow::Result<()> {
Ok ( ( ) )
Ok ( ( ) )
}
}
#[ tokio::test ]
#[ tokio::test (flavor = " multi_thread " ) ]
async fn append_end_of_word_multi ( ) -> anyhow ::Result < ( ) > {
async fn append_end_of_word_multi ( ) -> anyhow ::Result < ( ) > {
for pair in differing_pairs ( ) {
for pair in differing_pairs ( ) {
test ( (
test ( (
@ -490,7 +490,7 @@ async fn append_end_of_word_multi() -> anyhow::Result<()> {
Ok ( ( ) )
Ok ( ( ) )
}
}
#[ tokio::test ]
#[ tokio::test (flavor = " multi_thread " ) ]
async fn append_inside_nested_pair ( ) -> anyhow ::Result < ( ) > {
async fn append_inside_nested_pair ( ) -> anyhow ::Result < ( ) > {
for pair in differing_pairs ( ) {
for pair in differing_pairs ( ) {
test ( (
test ( (
@ -514,7 +514,7 @@ async fn append_inside_nested_pair() -> anyhow::Result<()> {
Ok ( ( ) )
Ok ( ( ) )
}
}
#[ tokio::test ]
#[ tokio::test (flavor = " multi_thread " ) ]
async fn append_inside_nested_pair_multi ( ) -> anyhow ::Result < ( ) > {
async fn append_inside_nested_pair_multi ( ) -> anyhow ::Result < ( ) > {
for outer_pair in DEFAULT_PAIRS {
for outer_pair in DEFAULT_PAIRS {
for inner_pair in DEFAULT_PAIRS {
for inner_pair in DEFAULT_PAIRS {