diff --git a/tests/test_regexp.rs b/tests/test_regexp.rs --- a/tests/test_regexp.rs +++ b/tests/test_regexp.rs @@ -51,24 +51,6 @@ fn test_eval_asterisk_dfa() { } #[test] -fn test_eval_plus_nfa() { - let r = Regexp::new(&String::from("(ab)+")).unwrap(); - assert!(!r.eval(String::from("a"))); - assert!(r.eval(String::from("ab"))); - assert!(r.eval(String::from("abab"))); - assert!(!r.eval(String::from("aabb"))); -} - -#[test] -fn test_eval_plus_dfa() { - let r = Regexp::new(&String::from("(ab)+")).unwrap().determinize(); - assert!(!r.eval(String::from("a"))); - assert!(r.eval(String::from("ab"))); - assert!(r.eval(String::from("abab"))); - assert!(!r.eval(String::from("aabb"))); -} - -#[test] fn test_eval_alternative_nfa() { let r = Regexp::new(&String::from("a|b|c")).unwrap(); assert!(r.eval(String::from("a"))); @@ -121,12 +103,6 @@ fn test_invalid_asterisk() { } #[test] -fn test_invalid_plus() { - let x = Regexp::new(&String::from("+")); - assert!(matches!(x, Err(ParsingError::Plus{s: _, pos: 0}))); -} - -#[test] fn test_invalid_closing_parenthesis() { let x = Regexp::new(&String::from("(a")); assert!(matches!(x, Err(ParsingError::ClosingParenthesis{s: _, pos: 0})));