The following test shows that this invalid regex input is being successfully parsed by Rust's Regex crate, but according to URLPattern spec it should fail.
#[test]
fn test_test() {
let input = "((?R))"; // invalid in EcmaScript regex
let _ = <UrlPattern>::parse(
UrlPatternInit {
protocol: Some(input.to_string()),
..Default::default()
},
Default::default(),
)
.unwrap();
}
This currently passes because the following fragment passes:
let input = "((?R))";
let regexp = regex::Regex::new(input);
regexp.unwrap();
The following test shows that this invalid regex input is being successfully parsed by Rust's Regex crate, but according to URLPattern spec it should fail.
This currently passes because the following fragment passes: