diff options
author | Timothy Flynn <trflynn89@pm.me> | 2021-08-10 16:35:45 -0400 |
---|---|---|
committer | Andreas Kling <kling@serenityos.org> | 2021-08-11 13:11:01 +0200 |
commit | df14d11a11ba256dc8e7fcee4bffcdbc9934166f (patch) | |
tree | 2ec4eabbb5f44f2b1c722c0ea34c8794a1db40cd /Tests/LibRegex | |
parent | a98d3a1a851330aa0d33a73031566ba04cf6b53c (diff) | |
download | serenity-df14d11a11ba256dc8e7fcee4bffcdbc9934166f.zip |
LibRegex: Disallow invalid interval qualifiers in Unicode mode
Fixes all remaining 'built-ins/RegExp/property-escapes' test262 tests.
Diffstat (limited to 'Tests/LibRegex')
-rw-r--r-- | Tests/LibRegex/Regex.cpp | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/Tests/LibRegex/Regex.cpp b/Tests/LibRegex/Regex.cpp index dc7bad6b33..820d5401fa 100644 --- a/Tests/LibRegex/Regex.cpp +++ b/Tests/LibRegex/Regex.cpp @@ -522,6 +522,9 @@ TEST_CASE(ECMA262_parse) { "\\p{hello friends}", regex::Error::InvalidNameForProperty, ECMAScriptFlags::Unicode }, { "\\p{Prepended_Concatenation_Mark}", regex::Error::InvalidNameForProperty, ECMAScriptFlags::Unicode }, { "\\p{ASCII}", regex::Error::NoError, ECMAScriptFlags::Unicode }, + { "\\\\p{1}", regex::Error::NoError, ECMAScriptFlags::Unicode }, + { "\\\\p{AsCiI}", regex::Error::InvalidPattern, ECMAScriptFlags::Unicode }, + { "\\\\p{ASCII}", regex::Error::InvalidPattern, ECMAScriptFlags::Unicode }, }; for (auto& test : tests) { |