Richard Gibson
30eca7761b
Add assertion messages
2021-09-13 10:09:42 -04:00
Richard Gibson
1a655779f0
Test lastIndex overwrite with big lastIndex
2021-09-13 10:09:42 -04:00
rwaldron
717bcbaedd
Transform legacy format to harness assertions: test/built-ins/R*/**/*.js
2021-09-02 11:34:06 -07:00
Rick Waldron
ee3597ed57
chore: migrate $ERROR -> throw new Test262Error in test/built-ins/RegExp ( #3092 )
2021-07-28 13:49:34 -07:00
Ron Buckton
0d922ddc97
Fix lint error
2021-02-25 11:03:39 -05:00
Ron Buckton
64ea2d19e6
rename no-indices-array test
2021-02-25 11:03:39 -05:00
Ron Buckton
d66f270313
PR Feedback
2021-02-25 11:03:39 -05:00
Ron Buckton
a567e4c819
Updates to regexp-match-indices tests based on d-flag
2021-02-25 11:03:39 -05:00
Gus Caplan
1d31345a70
fixup
2020-10-08 18:05:00 -04:00
Gus Caplan
881c9e3ba5
move __proto__ tests
2020-10-08 18:05:00 -04:00
Rick Waldron
d576baf73f
Info: adds "sec-evaluatenew" step to info for all "not-a-constructor.js" tests.
2020-10-06 12:01:34 -04:00
Rick Waldron
8aacff591c
Standardize built-in constructor testing
2020-10-06 12:01:34 -04:00
Rick Waldron
c644ede430
Built-in function objects that are not identified as constructors must throw a TypeError exception when new'ed. Fixes gh-1739
2020-10-06 12:01:34 -04:00
Alexey Shvayka
323905b70e
Improve RegExp.prototype[@@replace] poisoned stdlib test
2020-09-10 16:24:23 -04:00
Alexey Shvayka
54ef2ae71d
Test RegExp.prototype.toString called as top-level function
2020-09-09 14:34:20 -04:00
Alexey Shvayka
7a4b88e446
Add `null` named capture coercion test case
2020-04-23 10:48:48 -04:00
Alexey Shvayka
6de6484e21
Add functional replacement test
2020-04-23 10:48:48 -04:00
Alexey Shvayka
a6f3449cd8
Add string replacement test
2020-04-23 10:48:48 -04:00
Alexey Shvayka
eca34edd7e
Drop "the" and align license headers
2020-04-23 10:48:16 -04:00
Alexey Shvayka
3b5845afe7
Add invalid non-Unicode test
2020-04-23 10:48:16 -04:00
Alexey Shvayka
b0995ea174
Add invalid Unicode test
2020-04-23 10:48:16 -04:00
Alexey Shvayka
fd18971545
Add valid non-Unicode test
2020-04-23 10:48:16 -04:00
Alexey Shvayka
1991c24d91
Add valid Unicode test
2020-04-23 10:48:16 -04:00
Gus Caplan
1d513c3a50
Update indices-groups-object.js
2020-04-18 17:04:51 -04:00
Gus Caplan
a799a4ac23
Sort out __proto__ occurances outside of annexB
2020-04-18 17:04:51 -04:00
Michaël Zasso
e1fb459313
Use slice in RegExp lookBehind test
...
This change allows the test to be run on engines that do not implement
Annex B.
2020-04-18 13:26:52 -04:00
Alexey Shvayka
1e63ce0eae
Improve String.prototype.@@replace poisoned stdlib test
2020-03-25 11:59:43 -04:00
Alexey Shvayka
9b71a7cada
Fix inconsistent indentation in YAML
2020-03-25 11:59:43 -04:00
Alexey Shvayka
dc21d6b0a4
Add "lastIndex" restore test
2020-03-23 14:34:16 -04:00
Alexey Shvayka
fe2dfe9525
Add "lastIndex" init test
2020-03-23 14:34:16 -04:00
Alexey Shvayka
b59d07937a
Add note on arbitrary large integer
2020-03-23 14:30:51 -04:00
Alexey Shvayka
669250d098
RegExp: Test Quantifier with large integer
2020-03-23 14:30:51 -04:00
Alexey Shvayka
8dccb69cc0
Replace "\b" with "\u0008"
2020-03-23 14:30:17 -04:00
Alexey Shvayka
2377131fd7
Test \b escape inside CharacterClass in Unicode RegExp
2020-03-23 14:30:17 -04:00
Alexey Shvayka
2cae20333d
Add functional replacer with empty result test
2020-03-23 14:29:04 -04:00
Alexey Shvayka
8e41e8b439
Add "lastIndex" length abrupt coercion test
2020-03-23 14:29:04 -04:00
Alexey Shvayka
0485b839a6
Add "lastIndex" length coercion test
2020-03-23 14:29:04 -04:00
Alexey Shvayka
807afd9120
Make "length" coercion test more precise
2020-03-23 14:29:04 -04:00
Alexey Shvayka
3f6b961428
Make "index" integer coercion test more precise
2020-03-23 14:29:04 -04:00
Alexey Shvayka
53d16acb3b
Add "index" integer coercion test with functional replacer
2020-03-23 14:29:04 -04:00
Alexey Shvayka
e3e0e0f629
Add named capture groups abrupt lookup tests
2020-03-23 14:29:04 -04:00
Alexey Shvayka
c9e1c1c2b8
Add named capture groups abrupt coercion tests
2020-03-23 14:29:04 -04:00
Alexey Shvayka
4d3db14653
Add named capture groups coercion tests
2020-03-23 14:29:04 -04:00
Alexey Shvayka
dbbe2e7cc7
Add "0" string coercion test with global RegExp
2020-03-23 14:29:04 -04:00
Alexey Shvayka
50d1419b00
Make string coercion tests more precise
2020-03-23 14:29:04 -04:00
Alexey Shvayka
cf583c96d8
Add poisoned stdlib test
2020-03-23 14:29:04 -04:00
Alexey Shvayka
67e58de839
Fix typo in file name
2020-03-23 14:29:04 -04:00
Mathias Bynens
25c9e334d3
Update RegExp property escape tests per Unicode v13.0.0 ( #2526 )
...
Upstream change in test generator:
11fa92ca64
Unicode v13.0.0:
https://unicode.org/versions/Unicode13.0.0/
2020-03-11 13:53:16 -07:00
Gus Caplan
a53f43e1ce
add missing newlines in tests
2019-11-10 20:18:56 -08:00
Leo Balter
d49777de27
Whitespace cleanups. CRLF => LF
2019-10-08 20:44:09 -04:00
Mathias Bynens
a898fe9826
Add missing `regexp-match-indices` feature tags ( #2395 )
2019-10-08 14:38:39 -04:00
Leo Balter
e2903e2648
Merge pull request #2366 from bocoup/unnecessary-includes
...
Remove unnecessary "includes" directives
2019-09-27 16:46:22 -04:00
Mike Pennisi
9cd62ffbd7
Improve coverage: ctor props of the global object
...
Prior to this commit, the descriptors of the constructor properties of
the global object were verified inconsistently, many independent
assertions occured in the same file, and that file test was poorly
located.
Restructure the relevant tests to improve coverage, follow convention,
and promote discoverability.
2019-09-27 15:39:10 -04:00
Mike Pennisi
f26c2a11bd
Remove unnecessary "includes" directives
...
The values defined by the referenced files are not used by these tests.
This makes their inclusion superfluous, which needlessly increases the
time to execute the tests and may confuse some readers.
2019-09-25 13:59:24 -04:00
Leo Balter
0fd3cf4d24
Some cleanup follow ups ( #2351 )
2019-09-18 14:15:53 -03:00
Ron Buckton
1056d8fde9
Add tests for regexp-match-indices ( #2309 )
...
* Add tests for regexp-match-indices
* Add tests for unicode matches based on presence of /u flag
* Added deepEqual helper, PR feedback
2019-09-18 13:39:12 -03:00
Leo Balter
ff9763729d
Remove duplicated es[56]id if esid is present
2019-08-05 10:54:37 -04:00
Mathias Bynens
a9abd418cc
Update RegExp property escape tests per Unicode v12.1.0 ( #2161 )
...
Ref. https://github.com/tc39/ecma262/issues/1530 .
2019-05-22 17:08:14 -04:00
Mathias Bynens
9339f8a5ce
Update RegExp Unicode property escape tests per Unicode 12 ( #2091 )
...
1cfedb79bb
https://github.com/tc39/ecma262/issues/1467
https://github.com/tc39/ecma262/pull/1468
2019-03-12 04:47:27 -04:00
Mike Pennisi
cc09757478
Test forward slash in RegularExpressionClassChar
2019-02-14 15:21:42 -05:00
Leo Balter
e403eea331
Fix false positives
2018-12-21 10:50:23 -05:00
Leo Balter
dec4e5df74
Merge pull request #1801 from mathiasbynens/issue-1634
...
Move `throw "…"` for negative parsing errors to a helper function
2018-11-13 17:23:09 -05:00
Rick Waldron
b1e15cd326
Merge pull request #1923 from bakkot/less-regex-eval
...
Reduce uses of `eval` for regex literal syntax
2018-11-08 09:18:48 -05:00
Kevin Gibbons
0160cab518
fix missing/duplicate tests
2018-11-07 13:52:44 -08:00
Mathias Bynens
e558b29b69
Optimize character class escape tests
...
Previously, these tests simply compared against an equivalent regular expression pattern by generating a large string containing either all code points up to U+FFFF or U+10FFFF, depending on the `u` flag, and then performing:
str.replace(re, '') === str.replace(otherRe, '');
These two `String#replace` calls can be optimized into a single `RegExp#test` call by following the pattern used in the property escapes tests at https://github.com/mathiasbynens/unicode-property-escapes-tests .
2018-11-06 16:14:14 -08:00
Mathias Bynens
01550ab13a
Sync with https://github.com/bocoup/test262-regexp-generator/pull/1
2018-11-06 15:24:07 -08:00
Kevin Gibbons
e80d8a184a
split unicode-property-names.js
2018-11-05 15:34:03 -08:00
Kevin Gibbons
9bc9116656
split unicode-malformed.js
2018-11-05 15:23:03 -08:00
Kevin Gibbons
296f47a008
split non-unicode-property-names.js
2018-11-05 15:12:23 -08:00
Kevin Gibbons
de339e98d6
split non-unicode-malformed.js
2018-11-05 14:58:03 -08:00
Richard Gibson
5b3d429e28
Move cross-realm tests into their own files
2018-11-02 14:39:23 -04:00
Richard Gibson
6da621f161
Assert error when invoking any %RegExpPrototype%-aware getter on cross-realm RegExp.prototype
2018-11-02 14:39:23 -04:00
Richard Gibson
9e0410814a
Test cross-realm use of RegExp source getter in both directions
2018-11-02 14:39:23 -04:00
Richard Gibson
823af01575
Assert error when invoking RegExp source getter on cross-realm RegExp.prototype
...
RegExp.prototype is not a RegExp, and the algorithm only special-cases
(same-realm) %RegExpPrototype%.
2018-11-02 14:39:23 -04:00
Mathias Bynens
b9daa57dcb
Rename to $DONOTEVALUATE per @leobalter's suggestion
2018-10-23 13:51:17 +02:00
Mathias Bynens
e3feffb01e
Move `throw "…"` for negative parsing errors to a helper function
...
Closes #1634 .
2018-10-23 13:51:16 +02:00
André Bargull
faed4fb089
Fix various test issues
2018-10-17 07:45:33 -07:00
Leo Balter
d544eacedf
assert calls order for Symbol.match on matchAll usage ( #1795 )
...
Fix #1794
2018-09-26 11:37:19 -04:00
André Bargull
3febd4c536
Update matchAll tests to reflect latest spec proposal
2018-09-26 10:38:35 -04:00
André Bargull
8879820a8f
Make RegExp/CharacterClassEscapes tests faster across all engines
2018-08-17 07:48:42 -07:00
Leo Balter
0fde488bb4
Update tests for CharacterClassEscapes in RegExps ( #1611 )
2018-07-09 12:30:33 -04:00
Mathias Bynens
c7ac073e73
Update tests for RegExp Unicode property escapes ( #1633 )
...
62cbe2f1cb
2018-07-09 12:26:53 -04:00
Leo Balter
012114a6c7
Update non whitespace RegExp tests
2018-06-18 15:53:08 -04:00
Rick Waldron
f90a52b396
Merge pull request #1587 from peterwmwong/update-matchall
...
Update tests for String.prototype.matchAll
2018-06-07 23:15:50 -04:00
peterwmwong
bbad9482e6
Update tests for String.prototype.matchAll
...
As per spec changes (https://github.com/tc39/proposal-string-matchall/pull/35 ), removed tests related to the removed IsRegExp call.
To prevent older implementations (not observing spec change) from passing, added a new test to verify the reduced number of observable calls to IsRegExp.
Also fix a misreference in `features` frontmatter.
2018-06-07 21:23:54 -05:00
Mathias Bynens
85d595effa
Update RegExp Unicode property escape tests per Unicode 11
...
Emoji data is now published as part of the Unicode standard itself, and thus follows the same version number.
Ref. f302c60c84
.
Ref. https://github.com/tc39/ecma262/pull/1218 .
Ref. https://github.com/tc39/ecma262/issues/1219 .
2018-06-07 15:32:41 +02:00
peterwmwong
f1e45d9e5e
Fleshed out tests for Symbol.matchAll, String.p.matchAll, RegExp.p[@@matchAll], and %RegExpStringIteratorPrototype%
...
Tests were updated and assuming https://github.com/tc39/proposal-string-matchall/pull/33 will be merged.
2018-03-17 22:48:31 -05:00
Jordan Harband
e15be1853b
String.prototype.matchAll: add tests for stage 3
...
`RegExp.prototype[Symbol.matchAll]`: Add basic tests.
2018-01-25 23:45:12 -08:00
Leo Balter
ac55e29ed0
Fix yaml consistency
2018-03-06 14:36:02 -05:00
André Bargull
f95b56ab28
Revert "js-beautify: make all indentation consistent (depth & character) ( #1409 )" ( #1412 )
...
This reverts commit a01de4a722
.
2018-02-09 12:09:47 -05:00
Rick Waldron
a01de4a722
js-beautify: make all indentation consistent (depth & character) ( #1409 )
2018-02-09 11:35:37 -05:00
André Bargull
f717982c94
Remove unused includes
2018-01-25 13:59:37 -05:00
André Bargull
8b50602099
Replace Annex-B __proto__ with Object.[gs]etPrototypeOf
2018-01-25 13:59:37 -05:00
Rick Waldron
92a2621901
Frontmatter: fixup "info: >" to "info: |"
2018-01-05 12:27:59 -05:00
Mathias Bynens
7446e885e9
[regexp-named-groups] Expand tests for `groups` property
...
The `groups` property must be created unconditionally. https://github.com/tc39/proposal-regexp-named-groups/pull/40
2017-12-20 15:33:37 -05:00
André Bargull
2d6a356699
Move incomplete_hex_unicode_escape.js to annexB
...
Fixes #1313
2017-11-01 08:23:43 -07:00
Mathias Bynens
4e7ed93da8
RegExp property escapes: test Extended_Pictographic
2017-10-22 10:05:05 -07:00
Zirak
d36a1777b4
Test for proper handling of incomplete hex escapes ( #1274 )
...
See relevant firefox bug: https://bugzilla.mozilla.org/show_bug.cgi?id=1408452
2017-10-16 13:04:51 -04:00
Daniel Ehrenberg
e6df79231d
Update RegExp named capture tests for spec change ( #1270 )
...
The RegExp named groups specification has changed to not throw
errors in certain cases. This patch updates the test262 tests to match
the new specification, and throws in an additional test that verifies
the interaction between named group syntax and other replacement.
The tests pass on a version of V8 which implements the new semantics.
92ceba518c
2017-10-13 14:16:16 -04:00
Leo Balter
c969153145
Fix a test looping for space separator chars
2017-09-26 14:13:29 -04:00