Skip to content

Commit

Permalink
fix linter issues
Browse files Browse the repository at this point in the history
  • Loading branch information
NarHakobyan committed Feb 13, 2025
1 parent 98c1db8 commit 5f50203
Showing 1 changed file with 16 additions and 8 deletions.
24 changes: 16 additions & 8 deletions charabia/src/normalizer/lowercase.rs
Original file line number Diff line number Diff line change
Expand Up @@ -43,23 +43,27 @@ mod test {
use crate::token::TokenKind;

fn tokens() -> Vec<Token<'static>> {
vec![Token {
vec![
Token {
lemma: Owned("PascalCase".to_string()),
char_end: 10,
byte_end: 10,
script: Script::Latin,
..Default::default()
}, Token {
},
Token {
lemma: Owned("ֆիզիկոսը".to_string()),
char_end: 8,
byte_end: 16,
script: Script::Armenian,
..Default::default()
}]
},
]
}

fn normalizer_result() -> Vec<Token<'static>> {
vec![Token {
vec![
Token {
lemma: Owned("pascalcase".to_string()),
char_end: 10,
byte_end: 10,
Expand All @@ -77,17 +81,20 @@ mod test {
(1, 1),
]),
..Default::default()
}, Token {
},
Token {
lemma: Owned("ֆիզիկոսը".to_string()),
char_end: 8,
byte_end: 16,
script: Script::Armenian,
..Default::default()
}]
},
]
}

fn normalized_tokens() -> Vec<Token<'static>> {
vec![Token {
vec![
Token {
lemma: Owned("pascalcase".to_string()),
char_end: 10,
byte_end: 10,
Expand All @@ -114,7 +121,8 @@ mod test {
script: Script::Armenian,
kind: TokenKind::Word,
..Default::default()
}]
},
]
}

test_normalizer!(LowercaseNormalizer, tokens(), normalizer_result(), normalized_tokens());
Expand Down

0 comments on commit 5f50203

Please sign in to comment.