Skip to content

Commit

Permalink
test: replace code test
Browse files Browse the repository at this point in the history
  • Loading branch information
Bisht13 committed Jan 20, 2024
1 parent 631073a commit 18b7810
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions packages/apis/src/extract_substrs.rs
Original file line number Diff line number Diff line change
Expand Up @@ -422,13 +422,13 @@ mod test {
}

#[test]
fn test_code_in_subject_valid() {
fn test_code_in_email_address_valid() {
let code_regex = DecomposedRegexConfig {
// max_byte_size: 1024,
parts: vec![
RegexPartConfig {
is_public: false,
regex_def: "CODE:0x".to_string(),
regex_def: "ACCOUNTKEY.0x".to_string(),
// max_size: 7,
// solidity: None
},
Expand All @@ -440,9 +440,9 @@ mod test {
},
],
};
let input_str = "subject:Email Wallet CODE:0x123abc";
let input_str = "sepolia+ACCOUNTKEY.0xabc123@sendeth.org";
let idxes = extract_substr_idxes(input_str, &code_regex).unwrap();
assert_eq!(idxes, vec![(28, 34)]);
assert_eq!(idxes, vec![(21, 27)]);
}

#[test]
Expand Down

0 comments on commit 18b7810

Please sign in to comment.