Mike Pennisi
b62a070221
Simplify test
...
Remove semantics which are not necessary to exercise the behavior under
test.
2021-09-07 17:47:06 -04:00
Richard Gibson
50f3fca7a0
Test Math.hypot argument coercion ( #3177 )
...
* Test Math.hypot argument coercion
* Fix constructor
2021-09-03 15:59:25 -04:00
Rick Waldron
69262f6743
Transform legacy format to harness assertions: test/built-ins/M*/**/*.js ( #3150 )
2021-08-11 12:20:01 -07:00
Rick Waldron
e4c53bef51
chore: migrate $ERROR -> throw new Test262Error in test/built-ins/Math ( #3088 )
2021-07-21 12:10:32 -07:00
Vlad
c1959a44a6
Math.max/min - each element coerced
2020-12-10 09:19:02 -05: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
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
Leo Balter
ff9763729d
Remove duplicated es[56]id if esid is present
2019-08-05 10:54:37 -04:00
Timothy Gu
5d39cad767
Add tests for roundTiesToEven rounding in Math.fround ( #2021 )
2019-01-28 11:33:14 -05:00
Rick Waldron
9f57733ed9
Test all no-construct no-call objects consistently ( #1520 )
...
Related to https://github.com/tc39/ecma262/pull/1177
2018-04-19 11:23:17 -04:00
Leo Balter
8add0d64b2
Fix whitespace
2018-02-15 18:04:03 -05:00
Rick Waldron
0bf08dff3d
built-ins/Math/*: make all indentation consistent (depth & character) ( #1435 )
2018-02-15 17:35:45 -05:00
Jeff Walden
a19993e269
Add tests for the behavior of INT32_MIN (-2147483648) as exponent with the exponentiation operator and with Math.pow (which shares the same core algorithm in the spec, but might be differently implemented in actual implementations). ( #1445 )
2018-02-14 17:02:39 -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
Rick Waldron
92a2621901
Frontmatter: fixup "info: >" to "info: |"
2018-01-05 12:27:59 -05:00
André Bargull
d59e30c95e
Remove execute bit from files ( #976 )
2017-04-13 16:24:07 -04:00
Leonardo Balter
238f4caa9a
Update length descriptor tests for Math properties
2017-03-14 10:50:01 -04:00
Leonardo Balter
f45341ca4e
Add and update descriptor tests for Math properties
2017-03-14 10:50:01 -04: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
Leonardo Balter
f3bfaa692d
Expand tests for Math.log1p
2016-06-27 16:04:17 -04:00
Leonardo Balter
080afac906
Update tests for Math.{sign,sin,trunc}
2016-06-27 16:04:17 -04:00
Leonardo Balter
e3e7a510ff
Expand tests for Math.imul
2016-06-27 16:04:17 -04:00
Leonardo Balter
80c1c46b53
Update tests for Math.hypot
2016-06-27 16:04:16 -04:00
Leonardo Balter
f88c93520d
Expand tests for Math.fround
2016-06-27 16:04:16 -04:00
Leonardo Balter
d6eb13b4b5
Expand tests for Math.clz32
2016-06-27 16:04:15 -04:00
Leonardo Balter
440211e96a
Update tests for Math.acosh
2016-06-27 16:04:15 -04:00
Leonardo Balter
561ac9e473
Extend coverage for Math.abs
2016-06-27 16:04:15 -04:00
Leonardo Balter
0f29f57fdc
Update Math functions to handle distinct -0 and +0
2016-06-27 16:04:15 -04:00
Leonardo Balter
13e01e4340
Add tests for Math.{max,min} handling zeros
2016-06-27 16:04:14 -04:00
Leonardo Balter
ec3a89ebb8
Add test for the Math object
2016-06-27 16:04:14 -04:00
Leonardo Balter
813bb5166c
Remove precision-equivalency tests
...
Due to specs approximation values, some tests are invalid as the harness
helpers rely on another approximated values as Math.LN2.
2016-06-20 17:44:11 -04:00
Mike Pennisi
b698c8b3ab
Add tests for Math constants
...
Closes gh-540
Because the specific value of each constant is specified as a
host-defined approximation, only the value type may be enforced by
Test262.
2016-04-18 14:39:37 -04:00
Mike Pennisi
f7aa31b41f
Remove over-specified tests
...
Except for a small set of expected input/output pairs, both ES5 and
ES2015 define the expected return value of these methods in terms of an
"implementation-dependent approximation." This makes it inappropriate to
enforce expectations for specific values, even if expressed imprecisely.
2016-04-18 14:36:49 -04:00
Mike Pennisi
6e61c27aa5
Avoid false positives
...
As written, the test for `Math.random` would pass if the runtime
erroneously produced a non-numeric value. Add the necessary assertions
to guard against this case.
2016-03-17 17:12:54 -04:00
Rick Waldron
104a134bc2
restore "info"
2016-02-22 16:41:45 -05:00
Rick Waldron
2a962f74be
id => esid
2016-02-22 14:47:47 -05:00
Rick Waldron
2a112a3190
Exponentiation Operator tests
2016-02-22 14:47:47 -05:00
André Bargull
ca61d9b876
Add missing tests for "length" and "name" properties of built-in functions
...
Note: Already uses the updated DataView function lengths from tc39/ecma262#266 (ES2016 Draft 2015-12-20)
2016-01-15 18:12:05 +01:00
Rick Waldron
a2554d909b
Merge branch 'remove-runTestCase-builtins-other' of https://github.com/anba/test262 into anba-remove-runTestCase-builtins-other
...
# By André Bargull
# Via André Bargull
* 'remove-runTestCase-builtins-other' of https://github.com/anba/test262 :
Replace runTestCase with assert helpers, rest [test/built-ins]
Replace runTestCase with assert helpers [test/built-ins]
Conflicts:
test/built-ins/Array/from/S22.1.2.1_T1.js
test/built-ins/Array/from/S22.1.2.1_T2.js
test/built-ins/Array/from/S22.1.2.1_T3.js
2015-09-04 13:25:41 -04:00
André Bargull
1b14708467
Replace runTestCase with assert helpers [test/built-ins]
2015-08-13 17:50:58 +02:00
Mike Pennisi
d6bbbc9aed
Add tests for well-known Symbol: @@toStringTag
2015-08-07 20:02:44 -04:00
André Bargull
33a7e03a76
Replace runTestCase with assert helpers [test/built-ins/Math]
2015-08-06 18:26:26 +02:00
Brian Terlson
2284a46ebf
Merge pull request #385 from anba/license
...
Change license headers to standard format
2015-07-17 11:03:07 -07:00
André Bargull
023c7aa69e
- Remove inline license
...
- Remove duplicate word
- Add missing license
2015-07-17 19:55:00 +02:00
André Bargull
a85f5039e0
Remove links to hg.ecmascript.org
2015-07-17 17:43:09 +02:00
Brian Terlson
a1437652ab
Merge pull request #313 from evilpie/includes
...
Use the more common array syntax for includes
2015-06-11 12:07:48 -04:00
Tom Schuster
64fd1026dd
Use the more common array syntax for includes
2015-06-10 14:56:16 +02:00
Brian Terlson
7eb27329b3
Merge pull request #307 from bocoup/remove-fail
...
Remove `$FAIL` function
2015-06-09 16:59:13 -07:00
Mike Pennisi
92890e6723
Remove `$FAIL` function
...
This function is equivalent to `$ERROR` (which is automatically included
in test environments). Remove the harness file that defines the
function, remove references to the file from test `includes` lists, and
update scripts to instead invoke the `$ERROR` function.
2015-06-09 19:44:25 -04:00