40 Commits

Author SHA1 Message Date
André Bargull
d59e30c95e Remove execute bit from files (#976) 2017-04-13 16:24:07 -04:00
Daniel Ehrenberg
2878106ca0 Fix offset for detached TypedArray test (#946)
Bug was reported by @anba at
https://github.com/tc39/ecma262/pull/852#issuecomment-291781031

Without this change, you'd expect a RangeError rather than a TypeError.
2017-04-06 12:05:43 -04:00
Leo Balter
89160ff5b7 Merge pull request #926 from littledan/typedarray-constructor-edge-case
* Tests for throwing a TypeError in the TypedArray constructor on a detached buffer

Detached buffer causes an exception
- If it's already detached going into the constructor
- If the byteOffset coercion causes it to be detached

Tests are valid in ES2017

* Test that TypedArray constructor throws when detaching buffer in length calculation

This test is only valid with the PR in https://github.com/tc39/ecma262/pull/852

* Rename files per review
2017-03-27 13:55:54 -04:00
Doug Ilijev
333fa10c63 Fix invalid YAML. (#929) 2017-03-23 10:35:01 -07:00
Daniel Ehrenberg
b86b7031b8 Rename files per review 2017-03-21 18:04:50 +01:00
Daniel Ehrenberg
dbb80c81a6 Test that TypedArray constructor throws when detaching buffer in length calculation
This test is only valid with the PR in https://github.com/tc39/ecma262/pull/852
2017-03-21 11:41:52 +01:00
Daniel Ehrenberg
68fafb4cbe Tests for throwing a TypeError in the TypedArray constructor on a detached buffer
Detached buffer causes an exception
- If it's already detached going into the constructor
- If the byteOffset coercion causes it to be detached

Tests are valid in ES2017
2017-03-21 11:39:53 +01:00
Leonardo Balter
340543bc11
Rename top level 'name' and 'length' bindings
Fix 850
2017-03-14 12:43:24 -04:00
Leo Balter
ea45caf046 fix $.agent to $262.agent (#876)
Fixes #875
2017-03-02 12:00:16 -05: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
Shu-yu Guo
a72ee6d912 SharedArrayBuffer and Atomics tests (#839) 2017-02-07 11:17:31 -05:00
Henrique Ferreiro
d1d91af256 Integer indexed property descriptor must be non-configurable (#786)
* Integer indexed property descriptor must be non-configurable

* Make the configurable key explicitly 'false'
2016-11-11 09:42:01 -08: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
Leonardo Balter
021d44822c Add tests for custom ctor returns on TypedArrays from and of 2016-07-05 16:29:23 -04:00
Leonardo Balter
09be4da196 Fix test for TypedArray(length)
Fixes gh-694
2016-07-05 16:29:21 -04:00
Leonardo Balter
cfc77c83e3 Update tests for TypedArrays, DataView and ArrayBuffer
Ref tc39/ecma262#410
2016-06-13 16:17:09 -04:00
jugglinmike
07dcff3e27 Add tests for CreateByeDataBlock (#663)
Ensure that all bytes of newly-created Data Block are initialized to
zero.
2016-06-03 12:38:03 -04:00
Leonardo Balter
f912927b1f [TypedArrays] Apply code consistency fixes after checks with JSHint 2016-05-27 15:59:14 -04:00
Leonardo Balter
bc42c6ab5c Add harness for byte conversion values
Update testTypedArrayConversions to require byteConversionValues
2016-05-25 10:10:50 -04:00
jugglinmike
b17ffc0298 Add tests for NaN handling with Typed Arrays (#623)
Ensure that NaN values are canonicalized consistently by all invocations
of SetValueInBuffer. Also ensure that `%TypedArray%.prototype.set` and
`%TypedArray%.prototype.slice` preserve the bit-level encoding of the
source data.

Use a set of experimentally-derived expressions known to produce NaN
values with distinct bit patterns in various platforms.
2016-05-12 10:16:03 -04: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
Leonardo Balter
04a3c28f7d Add tests for conversion operations on TypedArrays 2016-04-19 12:18:52 -04:00
Leonardo Balter
755b0d6117 Add tests for typedArrays extensibility
Ref: https://github.com/tc39/test262/pull/536#issuecomment-200455389
2016-04-01 15:34:14 -04:00
Leonardo Balter
3cb20b9df5 Add tests for internal methods of typedArray instances
Test specific behaviour for Integer Indexed exotic objects, WRT the
following internal methods:

- [[GetOwnProperty]]
- [[HasProperty]]
- [[DefineOwnProperty]]
- [[Get]]
- [[Set]]
- [[OwnPropertyKeys]]
2016-03-28 10:38:24 -04:00
Gorkem Yakin
6e912b0825 Merge pull request #518 from anba/typedarray_getownpropdesc_fixes
Fix test bugs
2016-03-02 13:22:29 -08:00
Leonardo Balter
6c56658974 Add tests for _TypedArray_.prototype methods 2016-03-01 15:36:34 -05:00
André Bargull
1517615a21 Fix test bugs 2016-02-23 18:55:06 +01:00
Leonardo Balter
bf782c8421 s/id/esid
Fixes #477
2016-02-22 09:47:42 -05:00
Gorkem Yakin
bd33b2b8e5 Merge pull request #509 from bocoup/typedarray-object-set
Add tests for _TypedArrays_(object) using object properties
2016-02-19 16:33:40 -08:00
Leonardo Balter
a61fca93fa Fix test for TypedArrays.from on callable function
TypedArrays constructors are still callable even if they trigger a
TypeError Exception when a new target is not defined
2016-02-18 13:39:49 -05:00
Leonardo Balter
c82ab8cdbd Add extra tests for _TypedArrays_(object) using object properties 2016-02-13 03:55:53 -02:00
Gorkem Yakin
428418d5c7 Replace remaining es7id tags with id 2016-02-12 16:27:10 -08:00
Leonardo Balter
76080eac08 Reuse %TypedArray%.from and .of tests on each TypedArray constructor 2016-02-12 16:02:36 -08:00
Leonardo Balter
048073a29a Add tests for _TypedArray_.from and of 2016-02-12 16:02:36 -08:00
Leonardo Balter
75952beee2 Move test file from TypedArray to TypedArrays folder 2016-02-05 11:58:55 -02:00
Leonardo Balter
0a30413b49 fixup! rename test files + review fixes 2016-02-05 11:53:33 -02:00
Leonardo Balter
d033b160cb fixup! Add tests for TypedArrays constructors 2016-02-05 11:53:32 -02:00
Leonardo Balter
7a8120fb63 fixup! Add tests for TypedArrays constructors 2016-02-05 11:53:32 -02:00
Leonardo Balter
f8a4229bfd Add tests for TypedArrays constructors 2016-02-05 11:53:32 -02:00
André Bargull
1bac79fbf3 Add basic surface tests for TypedArrays 2016-01-15 18:13:08 +01:00