Commit Graph

103 Commits

Author SHA1 Message Date
André Bargull 3febd4c536 Update matchAll tests to reflect latest spec proposal 2018-09-26 10:38:35 -04:00
Kevin Gibbons 89ec038cf2 remove some trailing commas in calls 2018-09-21 10:04:33 -04:00
Leo Balter 6c2503a810
Adds String.fromCodePoint to the features list (#1606) 2018-06-21 16:03:08 -04: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 5b3914a37b
String.prototype.matchAll: add tests for stage 3
`String.prototype.matchAll`: Add basic tests.
2018-01-25 00:25:10 -08:00
Rick Waldron 19ca734bea built-ins/String/*: make all indentation consistent (depth & character) (#1430) 2018-02-15 15:39:13 -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
Mathias Bynens 6fa2525107 [string-trimming] Fix whitespace tests
This patch fixes a typo (`\FEFF` → `\uFEFF`) and adds some missing whitespace symbols as a follow-up to https://github.com/tc39/test262/pull/1246.
2018-01-25 17:32:06 -05:00
Rick Waldron 966dfb4cd0 String.prototype.trimEnd,trimStart: add feature (per new convention) 2018-01-25 14:38:51 -05:00
Valerie R Young 05d1ddf670 Fixup edit to info 2018-01-25 14:10:41 -05:00
Valerie R Young 56d57956a0 Add this value object testing to trimEnd 2018-01-25 14:10:41 -05:00
Valerie R Young 2b7df61dd6 Fixup typos 2018-01-25 14:10:41 -05:00
Valerie R Young 828c8031ef Add tests for object to primitive returns object errors 2018-01-25 14:10:40 -05:00
Valerie R Young 7c0053358a Add tests for object to primitive method errors 2018-01-25 14:10:40 -05:00
Valerie R Young 94325316be Add tests for object to primitive call errors 2018-01-25 14:10:40 -05:00
Valerie R Young f945473767 Add test of object without to primitive functionality 2018-01-25 14:10:40 -05:00
Valerie R Young 232eec1f3b Completely rewrite ToPrimitive method priority testing 2018-01-25 14:10:40 -05:00
Valerie R Young fc86cef984 fix typos 2018-01-25 14:10:40 -05:00
Valerie R Young 6501563705 Add ToPrimitive method priority testing 2018-01-25 14:10:40 -05:00
Valerie R Young bdcb73ae27 Add tests for sucessful whitespace removing 2018-01-25 14:10:40 -05:00
Valerie R Young 583a67af4c Add number tests for trim(Start/End) 2018-01-25 14:10:14 -05:00
Valerie R Young 812e071f03 fixup: Add boolean/Symbol() tests for trim(Start/End) 2018-01-25 14:10:14 -05:00
Valerie R Young fdf8e8bd3f Fixup: Add object coercible tests for trim(start/End) 2018-01-25 14:10:14 -05:00
Valerie R Young 2905e6a293 fixup: Add initial tests for trim(Start/End/Left/Right) 2018-01-25 14:10:14 -05:00
Valerie R Young 0c796ea88b Add boolean/Symbol() tests for trim(Start/End) 2018-01-25 14:10:14 -05:00
Valerie R Young 3f42003974 Add object coercible tests for trim(start/End) 2018-01-25 14:10:14 -05:00
Valerie R Young 5931e313fc Add initial tests for trim(Start/End/Left/Right) 2018-01-25 14:10:14 -05:00
Rick Waldron 92a2621901 Frontmatter: fixup "info: >" to "info: |" 2018-01-05 12:27:59 -05:00
Josh Wolfe 5730f10114 generate some type coercion tests 2017-12-21 16:40:18 -05:00
Leo Balter b8abd71305 fix repeated features tags (#1266) 2017-10-06 12:29:33 -04:00
Rick Waldron a7b5a7aa97 Features.txt: Add string-trimming; replace "#" in feature tags (#1247) 2017-10-03 17:02:29 -04:00
Leo Balter 60782de95e Tag tests for U+180E and complete coverage for RegExp matching 2017-09-25 15:27:59 -04:00
Leo Balter 7cbbe51216 Add cross-realm feature 2017-09-22 15:29:10 -04:00
Rick Waldron e3447b8200 features: update all features flags for all test files with harness/* deps that require a feature flag 2017-09-08 12:34:19 -04:00
Josh Wolfe f83adad4bd test for String.prototype.indexOf first parameter type coercion 2017-09-08 10:15:19 -04:00
Josh Wolfe 0f3f22f6ab use informative stack traces instead of loops 2017-09-08 10:15:19 -04:00
Josh Wolfe 29938e9525 type coercion harness utilities 2017-09-08 10:15:19 -04:00
André Bargull d59e30c95e Remove execute bit from files (#976) 2017-04-13 16:24:07 -04:00
Leonardo Balter a7ee8fb735
Fix invalid String#indexOf test in a coercible Date instance
Fixes #793

As described by @ediosyncratic:

Date(0) flows through the given algorithm to ToDateString, which should:

> Return an implementation-dependent String value that represents tv as
> a date and time in the current time zone using a convenient, human-readable form.

The string is implementation-dependent and there is nothing constraining it to use
a two-digit day-of-month (so "Thu Jan 1, 1970, 0:0:0" would be valid), much less to
position it at index 8.
2017-03-13 19:07:06 -04:00
Rick Waldron fdd2fa9b1c Rename $ => $262. Fixes gh-802 (#823)
Signed-off-by: Rick Waldron <waldron.rick@gmail.com>
2017-03-01 16:34:15 -05:00
jugglinmike 71e573f7da Add tests for realm interactions (#688)
* Add tests for prototype realm inference

* Add tests for miscellaneous realm concerns

* Add tests for realm of spec-created Errors

In some cases, Error objects produced by the specification are
observable from ECMAScript code. Among these cases, some are further
differentiated in that they occur outside of any built-in function and
may be triggered through syntactic production directly. The current
realm record is commonly interpreted incorrectly under these
circumstances.

Add tests asserting that the expected realm record is used when
constructing such Error objects.

* Add tests for realm use in ArraySpeciesCreate

* Add tests for function realm retrieval

* Add tests for cross-realm behaviors of Symbols

* Add tests for GetValue and PutValue

* Add tests for realm of spec-created Arrays

In some cases, Arrays produced by CreateArrayFromList are observable
from ECMAScript code. Among these cases, two occur outside of any
built-in function and may be triggered through syntactic production
directly. The current realm record is commonly interpreted incorrectly
under these circumstances.

Add tests asserting that the expected realm record is used when
constructing arrays.

* Add test for spec-created object

* fixup! Add tests for realm of spec-created Errors

* fixup! Add tests for realm of spec-created Errors

* fixup! Add tests for prototype realm inference

* fixup! Add tests for miscellaneous realm concerns
2016-10-24 10:43:17 -07:00
jugglinmike c5cbf4122d Improve coverage for section 9 (#726)
* Assert creation of 'arguments' object

Ensure that the 'arguments' object is created in cases where it is not
required by the body but is required by the parameters.

* Add tests for cases that disable "arguments" map

* Add tests for NewTarget override of bound function

* Add test for properties of exotic String objects
2016-08-05 10:07:02 -07:00
Mathias Bynens 3a5a09eba2 Ensure U+180E is no longer considered whitespace
Ref. https://hashseed.blogspot.com/2014/08/in-ecma-262-5.html
Ref. https://github.com/tc39/ecma262/pull/300#issuecomment-181376767
Ref. 9b10d2a597

Fix and add @anba’s U+180E tests
2016-07-06 10:11:32 -04:00
jugglinmike f554f68ae9 Improve coverage for section 21: String (#712)
This changeset increases coverage for section 21, specifically "21.1 String
Objects".

* Add tests for "this" validation of String methods

* Add tests for ToNumber as used by String methods

* Add test for `length` prop of exotic String objs

* fixup! Add test for `length` prop of exotic String objs
2016-07-05 14:04:31 -07:00
Leo Balter e49d2661a8 Improve assertions comparing values to NaN (#690)
The global isNaN is not precise at all, and Number.isNaN is an ES6 feature that makes it preferrable to use assert's sameValue for NaN values, as it handles it internally using the comparison.
2016-07-01 11:22:55 -07:00
Ian Halliday 022888be9e Remove duplicate front matter keys (#621)
Fixes #620
2016-05-06 13:41:33 -04:00
Gorkem Yakin 7f88f29328 Merge branch 'bocoup/global-object' 2016-04-25 11:09:49 -07:00
Mike Pennisi eb644bb2da Reduce reliance on `fnGlobalObject.js`
This harness function is not necessary in the majority of cases in which
it is used. Remove its usage to simplify tests and decrease the amount
of domain-specific knowledge necessary to contribute to the test suite.

Persist the harness function itself for use by future tests for ES2015
modules (such a helper is necessary for tests that are interpreted as
module code).
2016-04-25 11:09:21 -07:00
Mike Pennisi 3d68fcc063 Increase coverage for Symbol constructor
Add new tests for invocation requirements; re-organize existing files
according to the language feature under test.
2016-04-25 10:59:22 -07:00