diff options
author | André Bargull <andre.bargull@gmail.com> | 2018-02-09 09:09:47 -0800 |
---|---|---|
committer | Leo Balter <leonardo.balter@gmail.com> | 2018-02-09 12:09:47 -0500 |
commit | f95b56ab28c5f18150f30fbfa889a4f6ba0e50a1 (patch) | |
tree | d403f704c1b6a1842f12df380651919beaaf5fef /test/built-ins/TypedArray | |
parent | a01de4a722d088055a7d84d8c691ddd7109edb34 (diff) | |
download | qtdeclarative-testsuites-f95b56ab28c5f18150f30fbfa889a4f6ba0e50a1.tar.gz |
Revert "js-beautify: make all indentation consistent (depth & character) (#1409)" (#1412)
This reverts commit a01de4a722d088055a7d84d8c691ddd7109edb34.
Diffstat (limited to 'test/built-ins/TypedArray')
83 files changed, 300 insertions, 351 deletions
diff --git a/test/built-ins/TypedArray/from/arylk-to-length-error.js b/test/built-ins/TypedArray/from/arylk-to-length-error.js index 87599eb3b..1cc2bd738 100644 --- a/test/built-ins/TypedArray/from/arylk-to-length-error.js +++ b/test/built-ins/TypedArray/from/arylk-to-length-error.js @@ -13,9 +13,7 @@ includes: [testTypedArray.js] features: [TypedArray] ---*/ -var arrayLike = { - length: {} -}; +var arrayLike = { length: {} }; arrayLike.length = { valueOf: function() { diff --git a/test/built-ins/TypedArray/from/mapfn-is-not-callable.js b/test/built-ins/TypedArray/from/mapfn-is-not-callable.js index f5831d833..906ec4746 100644 --- a/test/built-ins/TypedArray/from/mapfn-is-not-callable.js +++ b/test/built-ins/TypedArray/from/mapfn-is-not-callable.js @@ -54,4 +54,4 @@ assert.throws(TypeError, function() { assert.sameValue( getIterator, 0, "IsCallable(mapfn) check occurs before getting source[@@iterator]" -); +);
\ No newline at end of file diff --git a/test/built-ins/TypedArray/from/this-is-not-constructor.js b/test/built-ins/TypedArray/from/this-is-not-constructor.js index 589665226..ac7d1cc9e 100644 --- a/test/built-ins/TypedArray/from/this-is-not-constructor.js +++ b/test/built-ins/TypedArray/from/this-is-not-constructor.js @@ -15,9 +15,7 @@ features: [TypedArray] ---*/ var from = TypedArray.from; -var m = { - m() {} -}.m; +var m = { m() {} }.m; assert.throws(TypeError, function() { from.call(m, []); diff --git a/test/built-ins/TypedArray/of/invoked-as-func.js b/test/built-ins/TypedArray/of/invoked-as-func.js index 29ee64382..af8f8c8b6 100644 --- a/test/built-ins/TypedArray/of/invoked-as-func.js +++ b/test/built-ins/TypedArray/of/invoked-as-func.js @@ -17,5 +17,6 @@ features: [TypedArray] var of = TypedArray.of; -assert.throws(TypeError, function() { of (); +assert.throws(TypeError, function() { + of(); }); diff --git a/test/built-ins/TypedArray/of/this-is-not-constructor.js b/test/built-ins/TypedArray/of/this-is-not-constructor.js index 264e2e5b1..eb91d74a3 100644 --- a/test/built-ins/TypedArray/of/this-is-not-constructor.js +++ b/test/built-ins/TypedArray/of/this-is-not-constructor.js @@ -15,9 +15,7 @@ includes: [testTypedArray.js] features: [TypedArray] ---*/ -var m = { - m() {} -}.m; +var m = { m() {} }.m; assert.throws(TypeError, function() { TypedArray.of.call(m, []); diff --git a/test/built-ins/TypedArray/prototype/copyWithin/coerced-values-end.js b/test/built-ins/TypedArray/prototype/copyWithin/coerced-values-end.js index 7e8489831..1cd62be56 100644 --- a/test/built-ins/TypedArray/prototype/copyWithin/coerced-values-end.js +++ b/test/built-ins/TypedArray/prototype/copyWithin/coerced-values-end.js @@ -29,42 +29,48 @@ includes: [compareArray.js, testTypedArray.js] testWithTypedArrayConstructors(function(TA) { assert( compareArray( - new TA([0, 1, 2, 3]).copyWithin(1, 0, null), [0, 1, 2, 3] + new TA([0, 1, 2, 3]).copyWithin(1, 0, null), + [0, 1, 2, 3] ), 'null value coerced to 0' ); assert( compareArray( - new TA([0, 1, 2, 3]).copyWithin(1, 0, NaN), [0, 1, 2, 3] + new TA([0, 1, 2, 3]).copyWithin(1, 0, NaN), + [0, 1, 2, 3] ), 'NaN value coerced to 0' ); assert( compareArray( - new TA([0, 1, 2, 3]).copyWithin(1, 0, false), [0, 1, 2, 3] + new TA([0, 1, 2, 3]).copyWithin(1, 0, false), + [0, 1, 2, 3] ), 'false value coerced to 0' ); assert( compareArray( - new TA([0, 1, 2, 3]).copyWithin(1, 0, true), [0, 0, 2, 3] + new TA([0, 1, 2, 3]).copyWithin(1, 0, true), + [0, 0, 2, 3] ), 'true value coerced to 1' ); assert( compareArray( - new TA([0, 1, 2, 3]).copyWithin(1, 0, '-2'), [0, 0, 1, 3] + new TA([0, 1, 2, 3]).copyWithin(1, 0, '-2'), + [0, 0, 1, 3] ), 'string "-2" value coerced to integer -2' ); assert( compareArray( - new TA([0, 1, 2, 3]).copyWithin(1, 0, -2.5), [0, 0, 1, 3] + new TA([0, 1, 2, 3]).copyWithin(1, 0, -2.5), + [0, 0, 1, 3] ), 'float -2.5 value coerced to integer -2' ); diff --git a/test/built-ins/TypedArray/prototype/copyWithin/coerced-values-start.js b/test/built-ins/TypedArray/prototype/copyWithin/coerced-values-start.js index c6f766c08..96819e395 100644 --- a/test/built-ins/TypedArray/prototype/copyWithin/coerced-values-start.js +++ b/test/built-ins/TypedArray/prototype/copyWithin/coerced-values-start.js @@ -28,56 +28,64 @@ includes: [compareArray.js, testTypedArray.js] testWithTypedArrayConstructors(function(TA) { assert( compareArray( - new TA([0, 1, 2, 3]).copyWithin(1, undefined), [0, 0, 1, 2] + new TA([0, 1, 2, 3]).copyWithin(1, undefined), + [0, 0, 1, 2] ), 'undefined value coerced to 0' ); assert( compareArray( - new TA([0, 1, 2, 3]).copyWithin(1, false), [0, 0, 1, 2] + new TA([0, 1, 2, 3]).copyWithin(1, false), + [0, 0, 1, 2] ), 'false value coerced to 0' ); assert( compareArray( - new TA([0, 1, 2, 3]).copyWithin(1, NaN), [0, 0, 1, 2] + new TA([0, 1, 2, 3]).copyWithin(1, NaN), + [0, 0, 1, 2] ), 'NaN value coerced to 0' ); assert( compareArray( - new TA([0, 1, 2, 3]).copyWithin(1, null), [0, 0, 1, 2] + new TA([0, 1, 2, 3]).copyWithin(1, null), + [0, 0, 1, 2] ), 'null value coerced to 0' ); assert( compareArray( - new TA([0, 1, 2, 3]).copyWithin(0, true), [1, 2, 3, 3] + new TA([0, 1, 2, 3]).copyWithin(0, true), + [1, 2, 3, 3] ), 'true value coerced to 1' ); assert( compareArray( - new TA([0, 1, 2, 3]).copyWithin(0, '1'), [1, 2, 3, 3] + new TA([0, 1, 2, 3]).copyWithin(0, '1'), + [1, 2, 3, 3] ), 'string "1" value coerced to 1' ); assert( compareArray( - new TA([0, 1, 2, 3]).copyWithin(1, 0.5), [0, 0, 1, 2] + new TA([0, 1, 2, 3]).copyWithin(1, 0.5), + [0, 0, 1, 2] ), '0.5 float value coerced to integer 0' ); assert( compareArray( - new TA([0, 1, 2, 3]).copyWithin(0, 1.5), [1, 2, 3, 3] + new TA([0, 1, 2, 3]).copyWithin(0, 1.5), + [1, 2, 3, 3] ), '1.5 float value coerced to integer 1' ); diff --git a/test/built-ins/TypedArray/prototype/copyWithin/coerced-values-target.js b/test/built-ins/TypedArray/prototype/copyWithin/coerced-values-target.js index 44348b90f..8d0c2816d 100644 --- a/test/built-ins/TypedArray/prototype/copyWithin/coerced-values-target.js +++ b/test/built-ins/TypedArray/prototype/copyWithin/coerced-values-target.js @@ -28,56 +28,64 @@ includes: [compareArray.js, testTypedArray.js] testWithTypedArrayConstructors(function(TA) { assert( compareArray( - new TA([0, 1, 2, 3]).copyWithin(undefined, 1), [1, 2, 3, 3] + new TA([0, 1, 2, 3]).copyWithin(undefined, 1), + [1, 2, 3, 3] ), 'undefined value coerced to 0' ); assert( compareArray( - new TA([0, 1, 2, 3]).copyWithin(false, 1), [1, 2, 3, 3] + new TA([0, 1, 2, 3]).copyWithin(false, 1), + [1, 2, 3, 3] ), 'false value coerced to 0' ); assert( compareArray( - new TA([0, 1, 2, 3]).copyWithin(NaN, 1), [1, 2, 3, 3] + new TA([0, 1, 2, 3]).copyWithin(NaN, 1), + [1, 2, 3, 3] ), 'NaN value coerced to 0' ); assert( compareArray( - new TA([0, 1, 2, 3]).copyWithin(null, 1), [1, 2, 3, 3] + new TA([0, 1, 2, 3]).copyWithin(null, 1), + [1, 2, 3, 3] ), 'null value coerced to 0' ); assert( compareArray( - new TA([0, 1, 2, 3]).copyWithin(true, 0), [0, 0, 1, 2] + new TA([0, 1, 2, 3]).copyWithin(true, 0), + [0, 0, 1, 2] ), 'true value coerced to 1' ); assert( compareArray( - new TA([0, 1, 2, 3]).copyWithin('1', 0), [0, 0, 1, 2] + new TA([0, 1, 2, 3]).copyWithin('1', 0), + [0, 0, 1, 2] ), 'string "1" value coerced to 1' ); assert( compareArray( - new TA([0, 1, 2, 3]).copyWithin(0.5, 1), [1, 2, 3, 3] + new TA([0, 1, 2, 3]).copyWithin(0.5, 1), + [1, 2, 3, 3] ), '0.5 float value coerced to integer 0' ); assert( compareArray( - new TA([0, 1, 2, 3]).copyWithin(1.5, 0), [0, 0, 1, 2] + new TA([0, 1, 2, 3]).copyWithin(1.5, 0), + [0, 0, 1, 2] ), '1.5 float value coerced to integer 1' ); diff --git a/test/built-ins/TypedArray/prototype/copyWithin/negative-end.js b/test/built-ins/TypedArray/prototype/copyWithin/negative-end.js index 5e90c95bc..96c9823f8 100644 --- a/test/built-ins/TypedArray/prototype/copyWithin/negative-end.js +++ b/test/built-ins/TypedArray/prototype/copyWithin/negative-end.js @@ -31,56 +31,64 @@ includes: [compareArray.js, testTypedArray.js] testWithTypedArrayConstructors(function(TA) { assert( compareArray( - new TA([0, 1, 2, 3]).copyWithin(0, 1, -1), [1, 2, 2, 3] + new TA([0, 1, 2, 3]).copyWithin(0, 1, -1), + [1, 2, 2, 3] ), '[0, 1, 2, 3].copyWithin(0, 1, -1) -> [1, 2, 2, 3]' ); assert( compareArray( - new TA([0, 1, 2, 3, 4]).copyWithin(2, 0, -1), [0, 1, 0, 1, 2] + new TA([0, 1, 2, 3, 4]).copyWithin(2, 0, -1), + [0, 1, 0, 1, 2] ), '[0, 1, 2, 3, 4].copyWithin(2, 0, -1) -> [0, 1, 0, 1, 2]' ); assert( compareArray( - new TA([0, 1, 2, 3, 4]).copyWithin(1, 2, -2), [0, 2, 2, 3, 4] + new TA([0, 1, 2, 3, 4]).copyWithin(1, 2, -2), + [0, 2, 2, 3, 4] ), '[0, 1, 2, 3, 4].copyWithin(1, 2, -2) -> [0, 2, 2, 3, 4]' ); assert( compareArray( - new TA([0, 1, 2, 3]).copyWithin(0, -2, -1), [2, 1, 2, 3] + new TA([0, 1, 2, 3]).copyWithin(0, -2, -1), + [2, 1, 2, 3] ), '[0, 1, 2, 3].copyWithin(0, -2, -1) -> [2, 1, 2, 3]' ); assert( compareArray( - new TA([0, 1, 2, 3, 4]).copyWithin(2, -2, -1), [0, 1, 3, 3, 4] + new TA([0, 1, 2, 3, 4]).copyWithin(2, -2, -1), + [0, 1, 3, 3, 4] ), '[0, 1, 2, 3, 4].copyWithin(2, -2, 1) -> [0, 1, 3, 3, 4]' ); assert( compareArray( - new TA([0, 1, 2, 3]).copyWithin(-3, -2, -1), [0, 2, 2, 3] + new TA([0, 1, 2, 3]).copyWithin(-3, -2, -1), + [0, 2, 2, 3] ), '[0, 1, 2, 3].copyWithin(-3, -2, -1) -> [0, 2, 2, 3]' ); assert( compareArray( - new TA([0, 1, 2, 3, 4]).copyWithin(-2, -3, -1), [0, 1, 2, 2, 3] + new TA([0, 1, 2, 3, 4]).copyWithin(-2, -3, -1), + [0, 1, 2, 2, 3] ), '[0, 1, 2, 3, 4].copyWithin(-2, -3, -1) -> [0, 1, 2, 2, 3]' ); assert( compareArray( - new TA([0, 1, 2, 3, 4]).copyWithin(-5, -2, -1), [3, 1, 2, 3, 4] + new TA([0, 1, 2, 3, 4]).copyWithin(-5, -2, -1), + [3, 1, 2, 3, 4] ), '[0, 1, 2, 3, 4].copyWithin(-5, -2, -1) -> [3, 1, 2, 3, 4]' ); diff --git a/test/built-ins/TypedArray/prototype/copyWithin/negative-out-of-bounds-end.js b/test/built-ins/TypedArray/prototype/copyWithin/negative-out-of-bounds-end.js index cfd1c71b4..7c55118aa 100644 --- a/test/built-ins/TypedArray/prototype/copyWithin/negative-out-of-bounds-end.js +++ b/test/built-ins/TypedArray/prototype/copyWithin/negative-out-of-bounds-end.js @@ -31,70 +31,80 @@ includes: [compareArray.js, testTypedArray.js] testWithTypedArrayConstructors(function(TA) { assert( compareArray( - new TA([0, 1, 2, 3]).copyWithin(0, 1, -10), [0, 1, 2, 3] + new TA([0, 1, 2, 3]).copyWithin(0, 1, -10), + [0, 1, 2, 3] ), '[0, 1, 2, 3].copyWithin(0, 1, -10) -> [0, 1, 2, 3]' ); assert( compareArray( - new TA([1, 2, 3, 4, 5]).copyWithin(0, 1, -Infinity), [1, 2, 3, 4, 5] + new TA([1, 2, 3, 4, 5]).copyWithin(0, 1, -Infinity), + [1, 2, 3, 4, 5] ), '[1, 2, 3, 4, 5].copyWithin(0, 1, -Infinity) -> [1, 2, 3, 4, 5]' ); assert( compareArray( - new TA([0, 1, 2, 3]).copyWithin(0, -2, -10), [0, 1, 2, 3] + new TA([0, 1, 2, 3]).copyWithin(0, -2, -10), + [0, 1, 2, 3] ), '[0, 1, 2, 3].copyWithin(0, -2, -10) -> [0, 1, 2, 3]' ); assert( compareArray( - new TA([1, 2, 3, 4, 5]).copyWithin(0, -2, -Infinity), [1, 2, 3, 4, 5] + new TA([1, 2, 3, 4, 5]).copyWithin(0, -2, -Infinity), + [1, 2, 3, 4, 5] ), '[1, 2, 3, 4, 5].copyWithin(0, -2, -Infinity) -> [1, 2, 3, 4, 5]' ); assert( compareArray( - new TA([0, 1, 2, 3]).copyWithin(0, -9, -10), [0, 1, 2, 3] + new TA([0, 1, 2, 3]).copyWithin(0, -9, -10), + [0, 1, 2, 3] ), '[0, 1, 2, 3].copyWithin(0, -9, -10) -> [0, 1, 2, 3]' ); assert( compareArray( - new TA([1, 2, 3, 4, 5]).copyWithin(0, -9, -Infinity), [1, 2, 3, 4, 5] + new TA([1, 2, 3, 4, 5]).copyWithin(0, -9, -Infinity), + [1, 2, 3, 4, 5] ), '[1, 2, 3, 4, 5].copyWithin(0, -9, -Infinity) -> [1, 2, 3, 4, 5]' ); assert( compareArray( - new TA([0, 1, 2, 3]).copyWithin(-3, -2, -10), [0, 1, 2, 3] + new TA([0, 1, 2, 3]).copyWithin(-3, -2, -10), + [0, 1, 2, 3] ), '[0, 1, 2, 3].copyWithin(-3, -2, -10) -> [0, 1, 2, 3]' ); assert( compareArray( - new TA([1, 2, 3, 4, 5]).copyWithin(-3, -2, -Infinity), [1, 2, 3, 4, 5] + new TA([1, 2, 3, 4, 5]).copyWithin(-3, -2, -Infinity), + [1, 2, 3, 4, 5] ), '[1, 2, 3, 4, 5].copyWithin(-3, -2, -Infinity) -> [1, 2, 3, 4, 5]' ); assert( compareArray( - new TA([0, 1, 2, 3]).copyWithin(-7, -8, -9), [0, 1, 2, 3] + new TA([0, 1, 2, 3]).copyWithin(-7, -8, -9), + [0, 1, 2, 3] ), '[0, 1, 2, 3].copyWithin(-7, -8, -9) -> [0, 1, 2, 3]' ); assert( compareArray( - new TA([1, 2, 3, 4, 5]).copyWithin(-7, -8, -Infinity), [1, 2, 3, 4, 5] + new TA([1, 2, 3, 4, 5]).copyWithin(-7, -8, -Infinity), + [1, 2, 3, 4, 5] ), '[1, 2, 3, 4, 5].copyWithin(-7, -8, -Infinity) -> [1, 2, 3, 4, 5]' ); diff --git a/test/built-ins/TypedArray/prototype/copyWithin/negative-out-of-bounds-start.js b/test/built-ins/TypedArray/prototype/copyWithin/negative-out-of-bounds-start.js index ead2f737e..4fdc4eb12 100644 --- a/test/built-ins/TypedArray/prototype/copyWithin/negative-out-of-bounds-start.js +++ b/test/built-ins/TypedArray/prototype/copyWithin/negative-out-of-bounds-start.js @@ -29,56 +29,64 @@ includes: [compareArray.js, testTypedArray.js] testWithTypedArrayConstructors(function(TA) { assert( compareArray( - new TA([0, 1, 2, 3]).copyWithin(0, -10), [0, 1, 2, 3] + new TA([0, 1, 2, 3]).copyWithin(0, -10), + [0, 1, 2, 3] ), '[0, 1, 2, 3]).copyWithin(0, -10) -> [0, 1, 2, 3]' ); assert( compareArray( - new TA([1, 2, 3, 4, 5]).copyWithin(0, -Infinity), [1, 2, 3, 4, 5] + new TA([1, 2, 3, 4, 5]).copyWithin(0, -Infinity), + [1, 2, 3, 4, 5] ), '[1, 2, 3, 4, 5]).copyWithin(0, -Infinity) -> [1, 2, 3, 4, 5]' ); assert( compareArray( - new TA([0, 1, 2, 3, 4]).copyWithin(2, -10), [0, 1, 0, 1, 2] + new TA([0, 1, 2, 3, 4]).copyWithin(2, -10), + [0, 1, 0, 1, 2] ), '[0, 1, 2, 3, 4]).copyWithin(2, -2) -> [0, 1, 0, 1, 2]' ); assert( compareArray( - new TA([1, 2, 3, 4, 5]).copyWithin(2, -Infinity), [1, 2, 1, 2, 3] + new TA([1, 2, 3, 4, 5]).copyWithin(2, -Infinity), + [1, 2, 1, 2, 3] ), '[1, 2, 3, 4, 5]).copyWithin(2, -Infinity) -> [1, 2, 1, 2, 3]' ); assert( compareArray( - new TA([0, 1, 2, 3, 4]).copyWithin(10, -10), [0, 1, 2, 3, 4] + new TA([0, 1, 2, 3, 4]).copyWithin(10, -10), + [0, 1, 2, 3, 4] ), '[0, 1, 2, 3, 4]).copyWithin(10, -10) -> [0, 1, 2, 3, 4]' ); assert( compareArray( - new TA([1, 2, 3, 4, 5]).copyWithin(10, -Infinity), [1, 2, 3, 4, 5] + new TA([1, 2, 3, 4, 5]).copyWithin(10, -Infinity), + [1, 2, 3, 4, 5] ), '[1, 2, 3, 4, 5]).copyWithin(10, -Infinity) -> [1, 2, 3, 4, 5]' ); assert( compareArray( - new TA([0, 1, 2, 3]).copyWithin(-9, -10), [0, 1, 2, 3] + new TA([0, 1, 2, 3]).copyWithin(-9, -10), + [0, 1, 2, 3] ), '[0, 1, 2, 3].copyWithin(-9, -10) -> [0, 1, 2, 3]' ); assert( compareArray( - new TA([1, 2, 3, 4, 5]).copyWithin(-9, -Infinity), [1, 2, 3, 4, 5] + new TA([1, 2, 3, 4, 5]).copyWithin(-9, -Infinity), + [1, 2, 3, 4, 5] ), '[1, 2, 3, 4, 5].copyWithin(-9, -Infinity) -> [1, 2, 3, 4, 5]' ); diff --git a/test/built-ins/TypedArray/prototype/copyWithin/negative-out-of-bounds-target.js b/test/built-ins/TypedArray/prototype/copyWithin/negative-out-of-bounds-target.js index 32b4818ad..dc46906d3 100644 --- a/test/built-ins/TypedArray/prototype/copyWithin/negative-out-of-bounds-target.js +++ b/test/built-ins/TypedArray/prototype/copyWithin/negative-out-of-bounds-target.js @@ -29,28 +29,32 @@ includes: [compareArray.js, testTypedArray.js] testWithTypedArrayConstructors(function(TA) { assert( compareArray( - new TA([0, 1, 2, 3]).copyWithin(-10, 0), [0, 1, 2, 3] + new TA([0, 1, 2, 3]).copyWithin(-10, 0), + [0, 1, 2, 3] ), '[0, 1, 2, 3].copyWithin(-10, 0) -> [0, 1, 2, 3]' ); assert( compareArray( - new TA([1, 2, 3, 4, 5]).copyWithin(-Infinity, 0), [1, 2, 3, 4, 5] + new TA([1, 2, 3, 4, 5]).copyWithin(-Infinity, 0), + [1, 2, 3, 4, 5] ), '[1, 2, 3, 4, 5].copyWithin(-Infinity, 0) -> [1, 2, 3, 4, 5]' ); assert( compareArray( - new TA([0, 1, 2, 3, 4]).copyWithin(-10, 2), [2, 3, 4, 3, 4] + new TA([0, 1, 2, 3, 4]).copyWithin(-10, 2), + [2, 3, 4, 3, 4] ), '[0, 1, 2, 3, 4].copyWithin(-10, 2) -> [2, 3, 4, 3, 4]' ); assert( compareArray( - new TA([1, 2, 3, 4, 5]).copyWithin(-Infinity, 2), [3, 4, 5, 4, 5] + new TA([1, 2, 3, 4, 5]).copyWithin(-Infinity, 2), + [3, 4, 5, 4, 5] ), '[1, 2, 3, 4, 5].copyWithin(-Infinity, 2) -> [3, 4, 5, 4, 5]' ); diff --git a/test/built-ins/TypedArray/prototype/copyWithin/negative-start.js b/test/built-ins/TypedArray/prototype/copyWithin/negative-start.js index 4552cab64..df73879d4 100644 --- a/test/built-ins/TypedArray/prototype/copyWithin/negative-start.js +++ b/test/built-ins/TypedArray/prototype/copyWithin/negative-start.js @@ -29,42 +29,48 @@ includes: [compareArray.js, testTypedArray.js] testWithTypedArrayConstructors(function(TA) { assert( compareArray( - new TA([0, 1, 2, 3]).copyWithin(0, -1), [3, 1, 2, 3] + new TA([0, 1, 2, 3]).copyWithin(0, -1), + [3, 1, 2, 3] ), '[0, 1, 2, 3].copyWithin(0, -1) -> [3, 1, 2, 3]' ); assert( compareArray( - new TA([0, 1, 2, 3, 4]).copyWithin(2, -2), [0, 1, 3, 4, 4] + new TA([0, 1, 2, 3, 4]).copyWithin(2, -2), + [0, 1, 3, 4, 4] ), '[0, 1, 2, 3, 4].copyWithin(2, -2) -> [0, 1, 3, 4, 4]' ); assert( compareArray( - new TA([0, 1, 2, 3, 4]).copyWithin(1, -2), [0, 3, 4, 3, 4] + new TA([0, 1, 2, 3, 4]).copyWithin(1, -2), + [0, 3, 4, 3, 4] ), '[0, 1, 2, 3, 4].copyWithin(1, -2) -> [0, 3, 4, 3, 4]' ); assert( compareArray( - new TA([0, 1, 2, 3]).copyWithin(-1, -2), [0, 1, 2, 2] + new TA([0, 1, 2, 3]).copyWithin(-1, -2), + [0, 1, 2, 2] ), '[0, 1, 2, 3].copyWithin(-1, -2) -> [ 0, 1, 2, 2 ]' ); assert( compareArray( - new TA([0, 1, 2, 3, 4]).copyWithin(-2, -3), [0, 1, 2, 2, 3] + new TA([0, 1, 2, 3, 4]).copyWithin(-2, -3), + [0, 1, 2, 2, 3] ), '[0, 1, 2, 3, 4].copyWithin(-2, -3) -> [0, 1, 2, 2, 3]' ); assert( compareArray( - new TA([0, 1, 2, 3, 4]).copyWithin(-5, -2), [3, 4, 2, 3, 4] + new TA([0, 1, 2, 3, 4]).copyWithin(-5, -2), + [3, 4, 2, 3, 4] ), '[0, 1, 2, 3, 4].copyWithin(-5, -2) -> [3, 4, 2, 3, 4]' ); diff --git a/test/built-ins/TypedArray/prototype/copyWithin/negative-target.js b/test/built-ins/TypedArray/prototype/copyWithin/negative-target.js index ad290241d..dfc252b1e 100644 --- a/test/built-ins/TypedArray/prototype/copyWithin/negative-target.js +++ b/test/built-ins/TypedArray/prototype/copyWithin/negative-target.js @@ -29,21 +29,24 @@ includes: [compareArray.js, testTypedArray.js] testWithTypedArrayConstructors(function(TA) { assert( compareArray( - new TA([0, 1, 2, 3]).copyWithin(-1, 0), [0, 1, 2, 0] + new TA([0, 1, 2, 3]).copyWithin(-1, 0), + [0, 1, 2, 0] ), '[0, 1, 2, 3].copyWithin(-1, 0) -> [0, 1, 2, 0]' ); assert( compareArray( - new TA([0, 1, 2, 3, 4]).copyWithin(-2, 2), [0, 1, 2, 2, 3] + new TA([0, 1, 2, 3, 4]).copyWithin(-2, 2), + [0, 1, 2, 2, 3] ), '[0, 1, 2, 3, 4].copyWithin(-2, 2) -> [0, 1, 2, 2, 3]' ); assert( compareArray( - new TA([0, 1, 2, 3]).copyWithin(-1, 2), [0, 1, 2, 2] + new TA([0, 1, 2, 3]).copyWithin(-1, 2), + [0, 1, 2, 2] ), '[0, 1, 2, 3].copyWithin(-1, 2) -> [0, 1, 2, 2]' ); diff --git a/test/built-ins/TypedArray/prototype/copyWithin/non-negative-out-of-bounds-end.js b/test/built-ins/TypedArray/prototype/copyWithin/non-negative-out-of-bounds-end.js index 9a71f2a7d..9767106c0 100644 --- a/test/built-ins/TypedArray/prototype/copyWithin/non-negative-out-of-bounds-end.js +++ b/test/built-ins/TypedArray/prototype/copyWithin/non-negative-out-of-bounds-end.js @@ -22,28 +22,32 @@ includes: [compareArray.js, testTypedArray.js] testWithTypedArrayConstructors(function(TA) { assert( compareArray( - new TA([0, 1, 2, 3]).copyWithin(0, 1, 6), [1, 2, 3, 3] + new TA([0, 1, 2, 3]).copyWithin(0, 1, 6), + [1, 2, 3, 3] ), '[0, 1, 2, 3].copyWithin(0, 1, 6) -> [1, 2, 3, 3]' ); assert( compareArray( - new TA([1, 2, 3, 4, 5]).copyWithin(0, 1, Infinity), [2, 3, 4, 5, 5] + new TA([1, 2, 3, 4, 5]).copyWithin(0, 1, Infinity), + [2, 3, 4, 5, 5] ), '[1, 2, 3, 4, 5].copyWithin(0, 1, Infinity) -> [2, 3, 4, 5, 5]' ); assert( compareArray( - new TA([0, 1, 2, 3, 4, 5]).copyWithin(1, 3, 6), [0, 3, 4, 5, 4, 5] + new TA([0, 1, 2, 3, 4, 5]).copyWithin(1, 3, 6), + [0, 3, 4, 5, 4, 5] ), '[0, 1, 2, 3, 4, 5].copyWithin(1, 3, 6) -> [0, 3, 4, 5, 4, 5]' ); assert( compareArray( - new TA([1, 2, 3, 4, 5]).copyWithin(1, 3, Infinity), [1, 4, 5, 4, 5] + new TA([1, 2, 3, 4, 5]).copyWithin(1, 3, Infinity), + [1, 4, 5, 4, 5] ), '[1, 2, 3, 4, 5].copyWithin(1, 3, Infinity) -> [1, 4, 5, 4, 5]' ); diff --git a/test/built-ins/TypedArray/prototype/copyWithin/non-negative-out-of-bounds-target-and-start.js b/test/built-ins/TypedArray/prototype/copyWithin/non-negative-out-of-bounds-target-and-start.js index 4dfbf4f4d..f1cc0504a 100644 --- a/test/built-ins/TypedArray/prototype/copyWithin/non-negative-out-of-bounds-target-and-start.js +++ b/test/built-ins/TypedArray/prototype/copyWithin/non-negative-out-of-bounds-target-and-start.js @@ -22,45 +22,52 @@ includes: [compareArray.js, testTypedArray.js] testWithTypedArrayConstructors(function(TA) { assert( compareArray( - new TA([0, 1, 2, 3, 4, 5]).copyWithin(6, 0), [0, 1, 2, 3, 4, 5] + new TA([0, 1, 2, 3, 4, 5]).copyWithin(6, 0), + [0, 1, 2, 3, 4, 5] ) ); assert( compareArray( - new TA([1, 2, 3, 4, 5]).copyWithin(Infinity, 0), [1, 2, 3, 4, 5] + new TA([1, 2, 3, 4, 5]).copyWithin(Infinity, 0), + [1, 2, 3, 4, 5] ), '[1, 2, 3, 4, 5].copyWithin(Infinity, 0) -> [1, 2, 3, 4, 5]' ); assert( compareArray( - new TA([0, 1, 2, 3, 4, 5]).copyWithin(0, 6), [0, 1, 2, 3, 4, 5] + new TA([0, 1, 2, 3, 4, 5]).copyWithin(0, 6), + [0, 1, 2, 3, 4, 5] ) ); assert( compareArray( - new TA([1, 2, 3, 4, 5]).copyWithin(0, Infinity), [1, 2, 3, 4, 5] + new TA([1, 2, 3, 4, 5]).copyWithin(0, Infinity), + [1, 2, 3, 4, 5] ), '[1, 2, 3, 4, 5].copyWithin(0, Infinity) -> [1, 2, 3, 4, 5]' ); assert( compareArray( - new TA([0, 1, 2, 3, 4, 5]).copyWithin(6, 6), [0, 1, 2, 3, 4, 5] + new TA([0, 1, 2, 3, 4, 5]).copyWithin(6, 6), + [0, 1, 2, 3, 4, 5] ) ); assert( compareArray( - new TA([0, 1, 2, 3, 4, 5]).copyWithin(10, 10), [0, 1, 2, 3, 4, 5] + new TA([0, 1, 2, 3, 4, 5]).copyWithin(10, 10), + [0, 1, 2, 3, 4, 5] ) ); assert( compareArray( - new TA([1, 2, 3, 4, 5]).copyWithin(Infinity, Infinity), [1, 2, 3, 4, 5] + new TA([1, 2, 3, 4, 5]).copyWithin(Infinity, Infinity), + [1, 2, 3, 4, 5] ), '[1, 2, 3, 4, 5].copyWithin(Infinity, Infinity) -> [1, 2, 3, 4, 5]' ); diff --git a/test/built-ins/TypedArray/prototype/copyWithin/non-negative-target-and-start.js b/test/built-ins/TypedArray/prototype/copyWithin/non-negative-target-and-start.js index f237de5a4..4dec6eff8 100644 --- a/test/built-ins/TypedArray/prototype/copyWithin/non-negative-target-and-start.js +++ b/test/built-ins/TypedArray/prototype/copyWithin/non-negative-target-and-start.js @@ -22,25 +22,29 @@ includes: [compareArray.js, testTypedArray.js] testWithTypedArrayConstructors(function(TA) { assert( compareArray( - new TA([1, 2, 3, 4, 5, 6]).copyWithin(0, 0), [1, 2, 3, 4, 5, 6] + new TA([1, 2, 3, 4, 5, 6]).copyWithin(0, 0), + [1, 2, 3, 4, 5, 6] ) ); assert( compareArray( - new TA([1, 2, 3, 4, 5, 6]).copyWithin(0, 2), [3, 4, 5, 6, 5, 6] + new TA([1, 2, 3, 4, 5, 6]).copyWithin(0, 2), + [3, 4, 5, 6, 5, 6] ) ); assert( compareArray( - new TA([1, 2, 3, 4, 5, 6]).copyWithin(3, 0), [1, 2, 3, 1, 2, 3] + new TA([1, 2, 3, 4, 5, 6]).copyWithin(3, 0), + [1, 2, 3, 1, 2, 3] ) ); assert( compareArray( - new TA([0, 1, 2, 3, 4, 5]).copyWithin(1, 4), [0, 4, 5, 3, 4, 5] + new TA([0, 1, 2, 3, 4, 5]).copyWithin(1, 4), + [0, 4, 5, 3, 4, 5] ) ); }); diff --git a/test/built-ins/TypedArray/prototype/copyWithin/non-negative-target-start-and-end.js b/test/built-ins/TypedArray/prototype/copyWithin/non-negative-target-start-and-end.js index 21d0ec476..c8cd09f17 100644 --- a/test/built-ins/TypedArray/prototype/copyWithin/non-negative-target-start-and-end.js +++ b/test/built-ins/TypedArray/prototype/copyWithin/non-negative-target-start-and-end.js @@ -22,21 +22,24 @@ includes: [compareArray.js, testTypedArray.js] testWithTypedArrayConstructors(function(TA) { assert( compareArray( - new TA([0, 1, 2, 3]).copyWithin(0, 0, 0), [0, 1, 2, 3] + new TA([0, 1, 2, 3]).copyWithin(0, 0, 0), + [0, 1, 2, 3] ), '[0, 1, 2, 3].copyWithin(0, 0, 0) -> [0, 1, 2, 3]' ); assert( compareArray( - new TA([0, 1, 2, 3]).copyWithin(0, 0, 2), [0, 1, 2, 3] + new TA([0, 1, 2, 3]).copyWithin(0, 0, 2), + [0, 1, 2, 3] ), '[0, 1, 2, 3].copyWithin(0, 0, 2) -> [0, 1, 2, 3]' ); assert( compareArray( - new TA([0, 1, 2, 3]).copyWithin(0, 1, 2), [1, 1, 2, 3] + new TA([0, 1, 2, 3]).copyWithin(0, 1, 2), + [1, 1, 2, 3] ), '[0, 1, 2, 3].copyWithin(0, 1, 2) -> [1, 1, 2, 3]' ); @@ -54,14 +57,16 @@ testWithTypedArrayConstructors(function(TA) { */ assert( compareArray( - new TA([0, 1, 2, 3]).copyWithin(1, 0, 2), [0, 0, 1, 3] + new TA([0, 1, 2, 3]).copyWithin(1, 0, 2), + [0, 0, 1, 3] ), '[0, 1, 2, 3].copyWithin(1, 0, 2) -> [0, 0, 1, 3]' ); assert( compareArray( - new TA([0, 1, 2, 3, 4, 5]).copyWithin(1, 3, 5), [0, 3, 4, 3, 4, 5] + new TA([0, 1, 2, 3, 4, 5]).copyWithin(1, 3, 5), + [0, 3, 4, 3, 4, 5] ), '[0, 1, 2, 3, 4, 5].copyWithin(1, 3, 5) -> [0, 3, 4, 3, 4, 5]' ); diff --git a/test/built-ins/TypedArray/prototype/copyWithin/undefined-end.js b/test/built-ins/TypedArray/prototype/copyWithin/undefined-end.js index fe03f4332..bd011026f 100644 --- a/test/built-ins/TypedArray/prototype/copyWithin/undefined-end.js +++ b/test/built-ins/TypedArray/prototype/copyWithin/undefined-end.js @@ -29,14 +29,16 @@ includes: [compareArray.js, testTypedArray.js] testWithTypedArrayConstructors(function(TA) { assert( compareArray( - new TA([0, 1, 2, 3]).copyWithin(0, 1, undefined), [1, 2, 3, 3] + new TA([0, 1, 2, 3]).copyWithin(0, 1, undefined), + [1, 2, 3, 3] ), '[0, 1, 2, 3].copyWithin(0, 1, undefined) -> [1, 2, 3]' ); assert( compareArray( - new TA([0, 1, 2, 3]).copyWithin(0, 1), [1, 2, 3, 3] + new TA([0, 1, 2, 3]).copyWithin(0, 1), + [1, 2, 3, 3] ), '[0, 1, 2, 3].copyWithin(0, 1) -> [1, 2, 3, 3]' ); diff --git a/test/built-ins/TypedArray/prototype/every/callbackfn-this.js b/test/built-ins/TypedArray/prototype/every/callbackfn-this.js index 2e944bb49..a3e62feb8 100644 --- a/test/built-ins/TypedArray/prototype/every/callbackfn-this.js +++ b/test/built-ins/TypedArray/prototype/every/callbackfn-this.js @@ -27,9 +27,7 @@ includes: [testTypedArray.js] features: [TypedArray] ---*/ -var expected = (function() { - return this; -})(); +var expected = (function() { return this; })(); var thisArg = {}; testWithTypedArrayConstructors(function(TA) { diff --git a/test/built-ins/TypedArray/prototype/every/returns-false-if-any-cb-returns-false.js b/test/built-ins/TypedArray/prototype/every/returns-false-if-any-cb-returns-false.js index e45dd0aac..63cbe4d6b 100644 --- a/test/built-ins/TypedArray/prototype/every/returns-false-if-any-cb-returns-false.js +++ b/test/built-ins/TypedArray/prototype/every/returns-false-if-any-cb-returns-false.js @@ -26,7 +26,8 @@ testWithTypedArrayConstructors(function(TA) { [ false, "", - 0, -0, + 0, + -0, NaN, undefined, null diff --git a/test/built-ins/TypedArray/prototype/every/returns-true-if-every-cb-returns-true.js b/test/built-ins/TypedArray/prototype/every/returns-true-if-every-cb-returns-true.js index eaf69d7fb..84bdfc8ce 100644 --- a/test/built-ins/TypedArray/prototype/every/returns-true-if-every-cb-returns-true.js +++ b/test/built-ins/TypedArray/prototype/every/returns-true-if-every-cb-returns-true.js @@ -28,9 +28,12 @@ testWithTypedArrayConstructors(function(TA) { "test262", Symbol("1"), {}, - [], -1, - Infinity, -Infinity, - 0.1, -0.1 + [], + -1, + Infinity, + -Infinity, + 0.1, + -0.1 ]; var sample = new TA(values.length); var result = sample.every(function() { diff --git a/test/built-ins/TypedArray/prototype/every/values-are-not-cached.js b/test/built-ins/TypedArray/prototype/every/values-are-not-cached.js index a4f6bf9c4..d9afa33bb 100644 --- a/test/built-ins/TypedArray/prototype/every/values-are-not-cached.js +++ b/test/built-ins/TypedArray/prototype/every/values-are-not-cached.js @@ -31,7 +31,7 @@ testWithTypedArrayConstructors(function(TA) { sample.every(function(v, i) { if (i < sample.length - 1) { - sample[i + 1] = 42; + sample[i+1] = 42; } assert.sameValue( diff --git a/test/built-ins/TypedArray/prototype/fill/fill-values-conversion-once.js b/test/built-ins/TypedArray/prototype/fill/fill-values-conversion-once.js index a681825e4..f5e1bd6b7 100644 --- a/test/built-ins/TypedArray/prototype/fill/fill-values-conversion-once.js +++ b/test/built-ins/TypedArray/prototype/fill/fill-values-conversion-once.js @@ -18,13 +18,10 @@ testWithTypedArrayConstructors(function(TA) { var sample = new TA(2); var n = 1; - sample.fill({ - valueOf() { - return n++; - } - }); + sample.fill({ valueOf() { return n++; } }); assert.sameValue(n, 2, "additional unexpected ToNumber() calls"); assert.sameValue(sample[0], 1, "incorrect ToNumber result in index 0"); assert.sameValue(sample[1], 1, "incorrect ToNumber result in index 1"); }); + diff --git a/test/built-ins/TypedArray/prototype/fill/fill-values-non-numeric.js b/test/built-ins/TypedArray/prototype/fill/fill-values-non-numeric.js index 2bd3f1716..1d8cd4b6a 100644 --- a/test/built-ins/TypedArray/prototype/fill/fill-values-non-numeric.js +++ b/test/built-ins/TypedArray/prototype/fill/fill-values-non-numeric.js @@ -62,7 +62,7 @@ testWithTypedArrayConstructors(function(TA) { return 1; }, valueOf: function() { - return 7; + return 7; } }); assert.sameValue(sample[0], 7, "object valueOf conversion before toString"); diff --git a/test/built-ins/TypedArray/prototype/fill/fill-values.js b/test/built-ins/TypedArray/prototype/fill/fill-values.js index 53774de8a..70da31da6 100644 --- a/test/built-ins/TypedArray/prototype/fill/fill-values.js +++ b/test/built-ins/TypedArray/prototype/fill/fill-values.js @@ -31,7 +31,8 @@ includes: [compareArray.js, testTypedArray.js] testWithTypedArrayConstructors(function(TA) { assert( compareArray( - new TA().fill(8), [] + new TA().fill(8), + [] ), "does not fill an empty instance" ); diff --git a/test/built-ins/TypedArray/prototype/filter/callbackfn-this.js b/test/built-ins/TypedArray/prototype/filter/callbackfn-this.js index 183bea070..1fc599c7c 100644 --- a/test/built-ins/TypedArray/prototype/filter/callbackfn-this.js +++ b/test/built-ins/TypedArray/prototype/filter/callbackfn-this.js @@ -18,9 +18,7 @@ includes: [testTypedArray.js] features: [TypedArray] ---*/ -var expected = (function() { - return this; -})(); +var expected = (function() { return this; })(); var thisArg = {}; testWithTypedArrayConstructors(function(TA) { diff --git a/test/built-ins/TypedArray/prototype/filter/result-does-not-share-buffer.js b/test/built-ins/TypedArray/prototype/filter/result-does-not-share-buffer.js index b716641ec..bbd292d14 100644 --- a/test/built-ins/TypedArray/prototype/filter/result-does-not-share-buffer.js +++ b/test/built-ins/TypedArray/prototype/filter/result-does-not-share-buffer.js @@ -19,13 +19,9 @@ testWithTypedArrayConstructors(function(TA) { var sample = new TA([40, 41, 42]); var result; - result = sample.filter(function() { - return true; - }); + result = sample.filter(function() { return true; }); assert.notSameValue(result.buffer, sample.buffer); - result = sample.filter(function() { - return false; - }); + result = sample.filter(function() { return false; }); assert.notSameValue(result.buffer, sample.buffer); }); diff --git a/test/built-ins/TypedArray/prototype/filter/result-empty-callbackfn-returns-false.js b/test/built-ins/TypedArray/prototype/filter/result-empty-callbackfn-returns-false.js index c1b0ac9af..de558f97e 100644 --- a/test/built-ins/TypedArray/prototype/filter/result-empty-callbackfn-returns-false.js +++ b/test/built-ins/TypedArray/prototype/filter/result-empty-callbackfn-returns-false.js @@ -22,7 +22,8 @@ testWithTypedArrayConstructors(function(TA) { [ false, "", - 0, -0, + 0, + -0, NaN, undefined, null diff --git a/test/built-ins/TypedArray/prototype/filter/result-full-callbackfn-returns-true.js b/test/built-ins/TypedArray/prototype/filter/result-full-callbackfn-returns-true.js index 6ae2811eb..f46bf483d 100644 --- a/test/built-ins/TypedArray/prototype/filter/result-full-callbackfn-returns-true.js +++ b/test/built-ins/TypedArray/prototype/filter/result-full-callbackfn-returns-true.js @@ -25,13 +25,14 @@ testWithTypedArrayConstructors(function(TA) { "test262", Symbol("1"), {}, - [], -1, - Infinity, -Infinity, - 0.1, -0.1 + [], + -1, + Infinity, + -Infinity, + 0.1, + -0.1 ].forEach(function(val) { - var result = sample.filter(function() { - return val; - }); + var result = sample.filter(function() { return val; }); assert(compareArray(result, sample), val); }); }); diff --git a/test/built-ins/TypedArray/prototype/filter/speciesctor-get-ctor-returns-throws.js b/test/built-ins/TypedArray/prototype/filter/speciesctor-get-ctor-returns-throws.js index bb501ccf4..a63bd2e53 100644 --- a/test/built-ins/TypedArray/prototype/filter/speciesctor-get-ctor-returns-throws.js +++ b/test/built-ins/TypedArray/prototype/filter/speciesctor-get-ctor-returns-throws.js @@ -28,9 +28,7 @@ includes: [testTypedArray.js] features: [Symbol, TypedArray] ---*/ -var callbackfn = function() { - return true; -}; +var callbackfn = function() { return true; }; testWithTypedArrayConstructors(function(TA) { var sample = new TA([40, 41, 42, 43]); diff --git a/test/built-ins/TypedArray/prototype/filter/speciesctor-get-ctor.js b/test/built-ins/TypedArray/prototype/filter/speciesctor-get-ctor.js index 565da5179..6308fe92f 100644 --- a/test/built-ins/TypedArray/prototype/filter/speciesctor-get-ctor.js +++ b/test/built-ins/TypedArray/prototype/filter/speciesctor-get-ctor.js @@ -37,9 +37,7 @@ testWithTypedArrayConstructors(function(TA) { } }); - result = sample.filter(function() { - return true; - }); + result = sample.filter(function() { return true; }); assert.sameValue(calls, 1, "called custom ctor get accessor once"); diff --git a/test/built-ins/TypedArray/prototype/filter/speciesctor-get-species-abrupt.js b/test/built-ins/TypedArray/prototype/filter/speciesctor-get-species-abrupt.js index 8e2256efa..858dd0fa7 100644 --- a/test/built-ins/TypedArray/prototype/filter/speciesctor-get-species-abrupt.js +++ b/test/built-ins/TypedArray/prototype/filter/speciesctor-get-species-abrupt.js @@ -40,8 +40,6 @@ testWithTypedArrayConstructors(function(TA) { }); assert.throws(Test262Error, function() { - sample.filter(function() { - return true; - }); + sample.filter(function() { return true; }); }); }); diff --git a/test/built-ins/TypedArray/prototype/filter/speciesctor-get-species-custom-ctor-invocation.js b/test/built-ins/TypedArray/prototype/filter/speciesctor-get-species-custom-ctor-invocation.js index 2cfb9bcb8..ad8313a26 100644 --- a/test/built-ins/TypedArray/prototype/filter/speciesctor-get-species-custom-ctor-invocation.js +++ b/test/built-ins/TypedArray/prototype/filter/speciesctor-get-species-custom-ctor-invocation.js @@ -47,9 +47,7 @@ testWithTypedArrayConstructors(function(TA) { return new TA(count); }; - sample.filter(function(v) { - return v === 42; - }); + sample.filter(function(v) { return v === 42; }); assert.sameValue(result.length, 1, "called with 1 argument"); assert.sameValue(result[0], 2, "[0] is the new captured length"); diff --git a/test/built-ins/TypedArray/prototype/filter/speciesctor-get-species-custom-ctor-length-throws.js b/test/built-ins/TypedArray/prototype/filter/speciesctor-get-species-custom-ctor-length-throws.js index abf9ef13e..35f48124c 100644 --- a/test/built-ins/TypedArray/prototype/filter/speciesctor-get-species-custom-ctor-length-throws.js +++ b/test/built-ins/TypedArray/prototype/filter/speciesctor-get-species-custom-ctor-length-throws.js @@ -36,8 +36,6 @@ testWithTypedArrayConstructors(function(TA) { }; assert.throws(TypeError, function() { - sample.filter(function() { - return true; - }); + sample.filter(function() { return true; }); }); }); diff --git a/test/built-ins/TypedArray/prototype/filter/speciesctor-get-species-custom-ctor-length.js b/test/built-ins/TypedArray/prototype/filter/speciesctor-get-species-custom-ctor-length.js index fcf4bb693..35228670d 100644 --- a/test/built-ins/TypedArray/prototype/filter/speciesctor-get-species-custom-ctor-length.js +++ b/test/built-ins/TypedArray/prototype/filter/speciesctor-get-species-custom-ctor-length.js @@ -37,14 +37,10 @@ testWithTypedArrayConstructors(function(TA) { }; customCount = 2; - result = sample.filter(function() { - return true; - }); + result = sample.filter(function() { return true; }); assert.sameValue(result.length, customCount, "length == count"); customCount = 5; - result = sample.filter(function() { - return true; - }); + result = sample.filter(function() { return true; }); assert.sameValue(result.length, customCount, "length > count"); }); diff --git a/test/built-ins/TypedArray/prototype/filter/speciesctor-get-species-custom-ctor.js b/test/built-ins/TypedArray/prototype/filter/speciesctor-get-species-custom-ctor.js index 00836dd75..28e12b135 100644 --- a/test/built-ins/TypedArray/prototype/filter/speciesctor-get-species-custom-ctor.js +++ b/test/built-ins/TypedArray/prototype/filter/speciesctor-get-species-custom-ctor.js @@ -48,9 +48,7 @@ testWithTypedArrayConstructors(function(TA) { return other; }; - result = sample.filter(function() { - return true; - }); + result = sample.filter(function() { return true; }); assert.sameValue(calls, 1, "ctor called once"); assert.sameValue(result, other, "return is instance of custom constructor"); diff --git a/test/built-ins/TypedArray/prototype/filter/values-are-not-cached.js b/test/built-ins/TypedArray/prototype/filter/values-are-not-cached.js index 22b227163..1b24d310e 100644 --- a/test/built-ins/TypedArray/prototype/filter/values-are-not-cached.js +++ b/test/built-ins/TypedArray/prototype/filter/values-are-not-cached.js @@ -21,7 +21,7 @@ testWithTypedArrayConstructors(function(TA) { sample.filter(function(v, i) { if (i < sample.length - 1) { - sample[i + 1] = 42; + sample[i+1] = 42; } assert.sameValue( diff --git a/test/built-ins/TypedArray/prototype/filter/values-are-set.js b/test/built-ins/TypedArray/prototype/filter/values-are-set.js index 7ef152f17..c9f16b8df 100644 --- a/test/built-ins/TypedArray/prototype/filter/values-are-set.js +++ b/test/built-ins/TypedArray/prototype/filter/values-are-set.js @@ -20,9 +20,7 @@ testWithTypedArrayConstructors(function(TA) { var sample = new TA([41, 1, 42, 7]); var result; - result = sample.filter(function() { - return true; - }); + result = sample.filter(function() { return true; }); assert(compareArray(result, [41, 1, 42, 7]), "values are set #1"); result = sample.filter(function(v) { diff --git a/test/built-ins/TypedArray/prototype/find/get-length-ignores-length-prop.js b/test/built-ins/TypedArray/prototype/find/get-length-ignores-length-prop.js index ee2332f31..b62f9170f 100644 --- a/test/built-ins/TypedArray/prototype/find/get-length-ignores-length-prop.js +++ b/test/built-ins/TypedArray/prototype/find/get-length-ignores-length-prop.js @@ -49,9 +49,7 @@ testWithTypedArrayConstructors(function(TA) { }); assert.sameValue( - sample.find(function() { - return true; - }), + sample.find(function() { return true; }), 42 ); }); diff --git a/test/built-ins/TypedArray/prototype/find/predicate-call-changes-value.js b/test/built-ins/TypedArray/prototype/find/predicate-call-changes-value.js index 129eed845..556fb9851 100644 --- a/test/built-ins/TypedArray/prototype/find/predicate-call-changes-value.js +++ b/test/built-ins/TypedArray/prototype/find/predicate-call-changes-value.js @@ -44,7 +44,7 @@ testWithTypedArrayConstructors(function(TA) { sample = new TA(arr); result = sample.find(function(val, i) { - if (i === 0) { + if ( i === 0 ) { sample[2] = 7; } return val === 7; @@ -53,7 +53,7 @@ testWithTypedArrayConstructors(function(TA) { sample = new TA(arr); result = sample.find(function(val, i) { - if (i === 0) { + if ( i === 0 ) { sample[2] = 7; } return val === 3; @@ -62,7 +62,7 @@ testWithTypedArrayConstructors(function(TA) { sample = new TA(arr); result = sample.find(function(val, i) { - if (i > 0) { + if ( i > 0 ) { sample[0] = 7; } return val === 7; diff --git a/test/built-ins/TypedArray/prototype/find/return-found-value-predicate-result-is-true.js b/test/built-ins/TypedArray/prototype/find/return-found-value-predicate-result-is-true.js index 1feb9da2f..a2d0302c6 100644 --- a/test/built-ins/TypedArray/prototype/find/return-found-value-predicate-result-is-true.js +++ b/test/built-ins/TypedArray/prototype/find/return-found-value-predicate-result-is-true.js @@ -49,28 +49,18 @@ testWithTypedArrayConstructors(function(TA) { assert.sameValue(called, 3, "predicate was called three times"); assert.sameValue(result, 62, "returned true on sample[3]"); - result = sample.find(function() { - return "string"; - }); + result = sample.find(function() { return "string"; }); assert.sameValue(result, 39, "ToBoolean(string)"); - result = sample.find(function() { - return {}; - }); + result = sample.find(function() { return {}; }); assert.sameValue(result, 39, "ToBoolean(object)"); - result = sample.find(function() { - return Symbol(""); - }); + result = sample.find(function() { return Symbol(""); }); assert.sameValue(result, 39, "ToBoolean(symbol)"); - result = sample.find(function() { - return 1; - }); + result = sample.find(function() { return 1; }); assert.sameValue(result, 39, "ToBoolean(number)"); - result = sample.find(function() { - return -1; - }); + result = sample.find(function() { return -1; }); assert.sameValue(result, 39, "ToBoolean(negative number)"); }); diff --git a/test/built-ins/TypedArray/prototype/find/return-undefined-if-predicate-returns-false-value.js b/test/built-ins/TypedArray/prototype/find/return-undefined-if-predicate-returns-false-value.js index 2206d72aa..0133a6948 100644 --- a/test/built-ins/TypedArray/prototype/find/return-undefined-if-predicate-returns-false-value.js +++ b/test/built-ins/TypedArray/prototype/find/return-undefined-if-predicate-returns-false-value.js @@ -41,33 +41,21 @@ testWithTypedArrayConstructors(function(TA) { assert.sameValue(called, 3, "predicate was called three times"); assert.sameValue(result, undefined); - result = sample.find(function() { - return ""; - }); + result = sample.find(function() { return ""; }); assert.sameValue(result, undefined, "ToBoolean(empty string)"); - result = sample.find(function() { - return undefined; - }); + result = sample.find(function() { return undefined; }); assert.sameValue(result, undefined, "ToBoolean(undefined)"); - result = sample.find(function() { - return null; - }); + result = sample.find(function() { return null; }); assert.sameValue(result, undefined, "ToBoolean(null)"); - result = sample.find(function() { - return 0; - }); + result = sample.find(function() { return 0; }); assert.sameValue(result, undefined, "ToBoolean(0)"); - result = sample.find(function() { - return -0; - }); + result = sample.find(function() { return -0; }); assert.sameValue(result, undefined, "ToBoolean(-0)"); - result = sample.find(function() { - return NaN; - }); + result = sample.find(function() { return NaN; }); assert.sameValue(result, undefined, "ToBoolean(NaN)"); }); diff --git a/test/built-ins/TypedArray/prototype/findIndex/get-length-ignores-length-prop.js b/test/built-ins/TypedArray/prototype/findIndex/get-length-ignores-length-prop.js index 98d22f449..99566c3d5 100644 --- a/test/built-ins/TypedArray/prototype/findIndex/get-length-ignores-length-prop.js +++ b/test/built-ins/TypedArray/prototype/findIndex/get-length-ignores-length-prop.js @@ -47,9 +47,7 @@ testWithTypedArrayConstructors(function(TA) { }); assert.sameValue( - sample.findIndex(function() { - return true; - }), + sample.findIndex(function() { return true; }), 0 ); }); diff --git a/test/built-ins/TypedArray/prototype/findIndex/predicate-call-changes-value.js b/test/built-ins/TypedArray/prototype/findIndex/predicate-call-changes-value.js index 97652222c..84efabc26 100644 --- a/test/built-ins/TypedArray/prototype/findIndex/predicate-call-changes-value.js +++ b/test/built-ins/TypedArray/prototype/findIndex/predicate-call-changes-value.js @@ -40,7 +40,7 @@ testWithTypedArrayConstructors(function(TA) { sample = new TA(arr); result = sample.findIndex(function(val, i) { - if (i === 0) { + if ( i === 0 ) { sample[2] = 7; } return val === 7; @@ -49,7 +49,7 @@ testWithTypedArrayConstructors(function(TA) { sample = new TA(arr); result = sample.findIndex(function(val, i) { - if (i === 0) { + if ( i === 0 ) { sample[2] = 7; } return val === 30; @@ -58,10 +58,10 @@ testWithTypedArrayConstructors(function(TA) { sample = new TA(arr); result = sample.findIndex(function(val, i) { - if (i > 0) { + if ( i > 0 ) { sample[0] = 7; } return val === 7; }); assert.sameValue(result, -1, "value not found - changed after call"); -}); +});
\ No newline at end of file diff --git a/test/built-ins/TypedArray/prototype/findIndex/predicate-call-this-non-strict.js b/test/built-ins/TypedArray/prototype/findIndex/predicate-call-this-non-strict.js index 31c43d21f..68175c781 100644 --- a/test/built-ins/TypedArray/prototype/findIndex/predicate-call-this-non-strict.js +++ b/test/built-ins/TypedArray/prototype/findIndex/predicate-call-this-non-strict.js @@ -41,7 +41,7 @@ testWithTypedArrayConstructors(function(TA) { assert.sameValue(result, T, "without thisArg, predicate this is the global"); - result = null; + result = null; sample.findIndex(function() { result = this; }, undefined); diff --git a/test/built-ins/TypedArray/prototype/findIndex/predicate-is-not-callable-throws.js b/test/built-ins/TypedArray/prototype/findIndex/predicate-is-not-callable-throws.js index 18fdf425f..5b97bf74a 100644 --- a/test/built-ins/TypedArray/prototype/findIndex/predicate-is-not-callable-throws.js +++ b/test/built-ins/TypedArray/prototype/findIndex/predicate-is-not-callable-throws.js @@ -62,3 +62,4 @@ testWithTypedArrayConstructors(function(TA) { sample.findIndex(/./); }, "/./"); }); + diff --git a/test/built-ins/TypedArray/prototype/findIndex/return-index-predicate-result-is-true.js b/test/built-ins/TypedArray/prototype/findIndex/return-index-predicate-result-is-true.js index c1e0ce751..9e4880f22 100644 --- a/test/built-ins/TypedArray/prototype/findIndex/return-index-predicate-result-is-true.js +++ b/test/built-ins/TypedArray/prototype/findIndex/return-index-predicate-result-is-true.js @@ -49,28 +49,18 @@ testWithTypedArrayConstructors(function(TA) { assert.sameValue(called, 3, "predicate was called three times"); assert.sameValue(result, 2, "returned true on sample[3]"); - result = sample.findIndex(function() { - return "string"; - }); + result = sample.findIndex(function() { return "string"; }); assert.sameValue(result, 0, "ToBoolean(string)"); - result = sample.findIndex(function() { - return {}; - }); + result = sample.findIndex(function() { return {}; }); assert.sameValue(result, 0, "ToBoolean(object)"); - result = sample.findIndex(function() { - return Symbol(""); - }); + result = sample.findIndex(function() { return Symbol(""); }); assert.sameValue(result, 0, "ToBoolean(symbol)"); - result = sample.findIndex(function() { - return 1; - }); + result = sample.findIndex(function() { return 1; }); assert.sameValue(result, 0, "ToBoolean(number)"); - result = sample.findIndex(function() { - return -1; - }); + result = sample.findIndex(function() { return -1; }); assert.sameValue(result, 0, "ToBoolean(negative number)"); }); diff --git a/test/built-ins/TypedArray/prototype/findIndex/return-negative-one-if-predicate-returns-false-value.js b/test/built-ins/TypedArray/prototype/findIndex/return-negative-one-if-predicate-returns-false-value.js index 69f204717..f3367fbfa 100644 --- a/test/built-ins/TypedArray/prototype/findIndex/return-negative-one-if-predicate-returns-false-value.js +++ b/test/built-ins/TypedArray/prototype/findIndex/return-negative-one-if-predicate-returns-false-value.js @@ -39,33 +39,21 @@ testWithTypedArrayConstructors(function(TA) { assert.sameValue(called, 3, "predicate was called three times"); assert.sameValue(result, -1, "result is -1 when predicate returns are false"); - result = sample.findIndex(function() { - return ""; - }); + result = sample.findIndex(function() { return ""; }); assert.sameValue(result, -1, "ToBoolean(string)"); - result = sample.findIndex(function() { - return undefined; - }); + result = sample.findIndex(function() { return undefined; }); assert.sameValue(result, -1, "ToBoolean(undefined)"); - result = sample.findIndex(function() { - return null; - }); + result = sample.findIndex(function() { return null; }); assert.sameValue(result, -1, "ToBoolean(null)"); - result = sample.findIndex(function() { - return 0; - }); + result = sample.findIndex(function() { return 0; }); assert.sameValue(result, -1, "ToBoolean(0)"); - result = sample.findIndex(function() { - return -0; - }); + result = sample.findIndex(function() { return -0; }); assert.sameValue(result, -1, "ToBoolean(-0)"); - result = sample.findIndex(function() { - return NaN; - }); + result = sample.findIndex(function() { return NaN; }); assert.sameValue(result, -1, "ToBoolean(NaN)"); }); diff --git a/test/built-ins/TypedArray/prototype/forEach/arraylength-internal.js b/test/built-ins/TypedArray/prototype/forEach/arraylength-internal.js index 97b5ec91e..d387ae038 100644 --- a/test/built-ins/TypedArray/prototype/forEach/arraylength-internal.js +++ b/test/built-ins/TypedArray/prototype/forEach/arraylength-internal.js @@ -19,9 +19,7 @@ testWithTypedArrayConstructors(function(TA) { var sample1 = new TA(42); var loop = 0; - Object.defineProperty(sample1, "length", { - value: 1 - }); + Object.defineProperty(sample1, "length", {value: 1}); sample1.forEach(function() { loop++; @@ -46,3 +44,4 @@ testWithTypedArrayConstructors(function(TA) { assert.sameValue(loop, 7, "accessor descriptor"); }); + diff --git a/test/built-ins/TypedArray/prototype/forEach/callbackfn-this.js b/test/built-ins/TypedArray/prototype/forEach/callbackfn-this.js index e3595b538..926a219bc 100644 --- a/test/built-ins/TypedArray/prototype/forEach/callbackfn-this.js +++ b/test/built-ins/TypedArray/prototype/forEach/callbackfn-this.js @@ -27,9 +27,7 @@ includes: [testTypedArray.js] features: [TypedArray] ---*/ -var expected = (function() { - return this; -})(); +var expected = (function() { return this; })(); var thisArg = {}; testWithTypedArrayConstructors(function(TA) { diff --git a/test/built-ins/TypedArray/prototype/forEach/values-are-not-cached.js b/test/built-ins/TypedArray/prototype/forEach/values-are-not-cached.js index 125923bb5..10b311356 100644 --- a/test/built-ins/TypedArray/prototype/forEach/values-are-not-cached.js +++ b/test/built-ins/TypedArray/prototype/forEach/values-are-not-cached.js @@ -21,7 +21,7 @@ testWithTypedArrayConstructors(function(TA) { sample.forEach(function(v, i) { if (i < sample.length - 1) { - sample[i + 1] = 42; + sample[i+1] = 42; } assert.sameValue( diff --git a/test/built-ins/TypedArray/prototype/includes/get-length-uses-internal-arraylength.js b/test/built-ins/TypedArray/prototype/includes/get-length-uses-internal-arraylength.js index 8f317131a..eb10a80bd 100644 --- a/test/built-ins/TypedArray/prototype/includes/get-length-uses-internal-arraylength.js +++ b/test/built-ins/TypedArray/prototype/includes/get-length-uses-internal-arraylength.js @@ -21,19 +21,13 @@ includes: [testTypedArray.js] features: [TypedArray] ---*/ -Object.defineProperty(TypedArray.prototype, "length", { - value: 0 -}); +Object.defineProperty(TypedArray.prototype, "length", {value: 0}); testWithTypedArrayConstructors(function(TA) { var sample = new TA([7]); - Object.defineProperty(TA.prototype, "length", { - value: 0 - }); - Object.defineProperty(sample, "length", { - value: 0 - }); + Object.defineProperty(TA.prototype, "length", {value: 0}); + Object.defineProperty(sample, "length", {value: 0}); assert.sameValue(sample.includes(7), true); }); diff --git a/test/built-ins/TypedArray/prototype/indexOf/get-length-uses-internal-arraylength.js b/test/built-ins/TypedArray/prototype/indexOf/get-length-uses-internal-arraylength.js index 9fd299266..2703a0519 100644 --- a/test/built-ins/TypedArray/prototype/indexOf/get-length-uses-internal-arraylength.js +++ b/test/built-ins/TypedArray/prototype/indexOf/get-length-uses-internal-arraylength.js @@ -20,19 +20,13 @@ includes: [testTypedArray.js] features: [TypedArray] ---*/ -Object.defineProperty(TypedArray.prototype, "length", { - value: 0 -}); +Object.defineProperty(TypedArray.prototype, "length", {value: 0}); testWithTypedArrayConstructors(function(TA) { var sample = new TA([7]); - Object.defineProperty(TA.prototype, "length", { - value: 0 - }); - Object.defineProperty(sample, "length", { - value: 0 - }); + Object.defineProperty(TA.prototype, "length", {value: 0}); + Object.defineProperty(sample, "length", {value: 0}); assert.sameValue(sample.indexOf(7), 0); }); diff --git a/test/built-ins/TypedArray/prototype/join/custom-separator-result-from-tostring-on-each-simple-value.js b/test/built-ins/TypedArray/prototype/join/custom-separator-result-from-tostring-on-each-simple-value.js index edb4b0e8f..694f81db0 100644 --- a/test/built-ins/TypedArray/prototype/join/custom-separator-result-from-tostring-on-each-simple-value.js +++ b/test/built-ins/TypedArray/prototype/join/custom-separator-result-from-tostring-on-each-simple-value.js @@ -61,19 +61,10 @@ testWithTypedArrayConstructors(function(TA) { result = sample.join(true); assert.sameValue(result, "1true0true2true3true42true127"); - result = sample.join({ - toString: function() { - return "foo"; - } - }); + result = sample.join({ toString: function() { return "foo"; }}); assert.sameValue(result, "1foo0foo2foo3foo42foo127"); - result = sample.join({ - toString: undefined, - valueOf: function() { - return "bar"; - } - }); + result = sample.join({ toString: undefined, valueOf: function() { return "bar"; }}); assert.sameValue(result, "1bar0bar2bar3bar42bar127"); result = sample.join(false); diff --git a/test/built-ins/TypedArray/prototype/join/custom-separator-result-from-tostring-on-each-value.js b/test/built-ins/TypedArray/prototype/join/custom-separator-result-from-tostring-on-each-value.js index 7cdbdddd2..94caedf65 100644 --- a/test/built-ins/TypedArray/prototype/join/custom-separator-result-from-tostring-on-each-value.js +++ b/test/built-ins/TypedArray/prototype/join/custom-separator-result-from-tostring-on-each-value.js @@ -91,23 +91,14 @@ testWithTypedArrayConstructors(function(TA) { result = sample.join(separator); assert.sameValue(result, expected, "using: " + separator); - separator = { - toString: function() { - return "foo"; - } - }; + separator = { toString: function() { return "foo"; }}; expected = arr.map(function(_, i) { return sample[i].toString(); }).join(separator); result = sample.join(separator); assert.sameValue(result, expected, "using: " + separator); - separator = { - toString: undefined, - valueOf: function() { - return "bar"; - } - }; + separator = { toString: undefined, valueOf: function() { return "bar"; }}; expected = arr.map(function(_, i) { return sample[i].toString(); }).join(separator); diff --git a/test/built-ins/TypedArray/prototype/lastIndexOf/get-length-uses-internal-arraylength.js b/test/built-ins/TypedArray/prototype/lastIndexOf/get-length-uses-internal-arraylength.js index 6b51c26e4..076d0b8d8 100644 --- a/test/built-ins/TypedArray/prototype/lastIndexOf/get-length-uses-internal-arraylength.js +++ b/test/built-ins/TypedArray/prototype/lastIndexOf/get-length-uses-internal-arraylength.js @@ -20,19 +20,13 @@ includes: [testTypedArray.js] features: [TypedArray] ---*/ -Object.defineProperty(TypedArray.prototype, "length", { - value: 0 -}); +Object.defineProperty(TypedArray.prototype, "length", {value: 0}); testWithTypedArrayConstructors(function(TA) { var sample = new TA([7]); - Object.defineProperty(TA.prototype, "length", { - value: 0 - }); - Object.defineProperty(sample, "length", { - value: 0 - }); + Object.defineProperty(TA.prototype, "length", {value: 0}); + Object.defineProperty(sample, "length", {value: 0}); assert.sameValue(sample.lastIndexOf(7), 0); }); diff --git a/test/built-ins/TypedArray/prototype/map/arraylength-internal.js b/test/built-ins/TypedArray/prototype/map/arraylength-internal.js index 7d23a4e1a..0f9ec0807 100644 --- a/test/built-ins/TypedArray/prototype/map/arraylength-internal.js +++ b/test/built-ins/TypedArray/prototype/map/arraylength-internal.js @@ -18,9 +18,7 @@ testWithTypedArrayConstructors(function(TA) { var sample1 = new TA(42); var loop = 0; - Object.defineProperty(sample1, "length", { - value: 1 - }); + Object.defineProperty(sample1, "length", {value: 1}); sample1.map(function() { loop++; @@ -42,3 +40,4 @@ testWithTypedArrayConstructors(function(TA) { }); assert.sameValue(loop, 4, "accessor descriptor"); }); + diff --git a/test/built-ins/TypedArray/prototype/map/callbackfn-this.js b/test/built-ins/TypedArray/prototype/map/callbackfn-this.js index 525de88e3..43d3159bc 100644 --- a/test/built-ins/TypedArray/prototype/map/callbackfn-this.js +++ b/test/built-ins/TypedArray/prototype/map/callbackfn-this.js @@ -18,9 +18,7 @@ includes: [testTypedArray.js] features: [TypedArray] ---*/ -var expected = (function() { - return this; -})(); +var expected = (function() { return this; })(); var thisArg = {}; testWithTypedArrayConstructors(function(TA) { diff --git a/test/built-ins/TypedArray/prototype/map/values-are-not-cached.js b/test/built-ins/TypedArray/prototype/map/values-are-not-cached.js index 329faaffe..d2345b13c 100644 --- a/test/built-ins/TypedArray/prototype/map/values-are-not-cached.js +++ b/test/built-ins/TypedArray/prototype/map/values-are-not-cached.js @@ -16,7 +16,7 @@ testWithTypedArrayConstructors(function(TA) { sample.map(function(v, i) { if (i < sample.length - 1) { - sample[i + 1] = 42; + sample[i+1] = 42; } assert.sameValue( diff --git a/test/built-ins/TypedArray/prototype/reduce/callbackfn-this.js b/test/built-ins/TypedArray/prototype/reduce/callbackfn-this.js index 356e94943..8c56605bc 100644 --- a/test/built-ins/TypedArray/prototype/reduce/callbackfn-this.js +++ b/test/built-ins/TypedArray/prototype/reduce/callbackfn-this.js @@ -26,9 +26,7 @@ includes: [testTypedArray.js] features: [TypedArray] ---*/ -var expected = (function() { - return this; -})(); +var expected = (function() { return this; })(); testWithTypedArrayConstructors(function(TA) { var sample = new TA(3); diff --git a/test/built-ins/TypedArray/prototype/reduce/values-are-not-cached.js b/test/built-ins/TypedArray/prototype/reduce/values-are-not-cached.js index af963b379..e091df1f9 100644 --- a/test/built-ins/TypedArray/prototype/reduce/values-are-not-cached.js +++ b/test/built-ins/TypedArray/prototype/reduce/values-are-not-cached.js @@ -31,7 +31,7 @@ testWithTypedArrayConstructors(function(TA) { sample.reduce(function(a, v, i) { if (i < sample.length - 1) { - sample[i + 1] = 42; + sample[i+1] = 42; } assert.sameValue( diff --git a/test/built-ins/TypedArray/prototype/reduceRight/callbackfn-this.js b/test/built-ins/TypedArray/prototype/reduceRight/callbackfn-this.js index 56752442a..acddf6dd3 100644 --- a/test/built-ins/TypedArray/prototype/reduceRight/callbackfn-this.js +++ b/test/built-ins/TypedArray/prototype/reduceRight/callbackfn-this.js @@ -27,9 +27,7 @@ includes: [testTypedArray.js] features: [TypedArray] ---*/ -var expected = (function() { - return this; -})(); +var expected = (function() { return this; })(); testWithTypedArrayConstructors(function(TA) { var sample = new TA(3); diff --git a/test/built-ins/TypedArray/prototype/reduceRight/values-are-not-cached.js b/test/built-ins/TypedArray/prototype/reduceRight/values-are-not-cached.js index b4e720ca7..fb93d3e20 100644 --- a/test/built-ins/TypedArray/prototype/reduceRight/values-are-not-cached.js +++ b/test/built-ins/TypedArray/prototype/reduceRight/values-are-not-cached.js @@ -32,7 +32,7 @@ testWithTypedArrayConstructors(function(TA) { sample.reduceRight(function(a, v, i) { if (i > 0) { - sample[i - 1] = 42; + sample[i-1] = 42; } assert.sameValue( diff --git a/test/built-ins/TypedArray/prototype/set/array-arg-offset-tointeger.js b/test/built-ins/TypedArray/prototype/set/array-arg-offset-tointeger.js index 529006e21..a5ab52773 100644 --- a/test/built-ins/TypedArray/prototype/set/array-arg-offset-tointeger.js +++ b/test/built-ins/TypedArray/prototype/set/array-arg-offset-tointeger.js @@ -86,18 +86,10 @@ testWithTypedArrayConstructors(function(TA) { assert(compareArray(sample, [1, 42]), "[1]"); sample = new TA([1, 2]); - sample.set([42], { - valueOf: function() { - return 1; - } - }); + sample.set([42], { valueOf: function() {return 1;} }); assert(compareArray(sample, [1, 42]), "valueOf"); sample = new TA([1, 2]); - sample.set([42], { - toString: function() { - return 1; - } - }); + sample.set([42], { toString: function() {return 1;} }); assert(compareArray(sample, [1, 42]), "toString"); }); diff --git a/test/built-ins/TypedArray/prototype/set/array-arg-src-tonumber-value-conversions.js b/test/built-ins/TypedArray/prototype/set/array-arg-src-tonumber-value-conversions.js index 5cd1fe72e..d5e346f11 100644 --- a/test/built-ins/TypedArray/prototype/set/array-arg-src-tonumber-value-conversions.js +++ b/test/built-ins/TypedArray/prototype/set/array-arg-src-tonumber-value-conversions.js @@ -26,5 +26,5 @@ testTypedArrayConversions(byteConversionValues, function(TA, value, expected, in sample.set([value]); - assert.sameValue(sample[0], expected, "[" + value + "] => [" + expected + "]"); + assert.sameValue(sample[0], expected, "["+value+"] => ["+expected +"]"); }); diff --git a/test/built-ins/TypedArray/prototype/set/array-arg-src-tonumber-value-type-conversions.js b/test/built-ins/TypedArray/prototype/set/array-arg-src-tonumber-value-type-conversions.js index c7e54c720..0256df84e 100644 --- a/test/built-ins/TypedArray/prototype/set/array-arg-src-tonumber-value-type-conversions.js +++ b/test/built-ins/TypedArray/prototype/set/array-arg-src-tonumber-value-type-conversions.js @@ -35,9 +35,7 @@ var obj2 = { }; // undefined and NaN covered on typedArrayConversions -var arr = ["1", "", false, true, null, obj1, obj2, [], - [1] -]; +var arr = ["1", "", false, true, null, obj1, obj2, [], [1]]; testWithTypedArrayConstructors(function(TA) { var sample = new TA(arr.length); diff --git a/test/built-ins/TypedArray/prototype/set/typedarray-arg-offset-tointeger.js b/test/built-ins/TypedArray/prototype/set/typedarray-arg-offset-tointeger.js index a32337c72..7f63cb996 100644 --- a/test/built-ins/TypedArray/prototype/set/typedarray-arg-offset-tointeger.js +++ b/test/built-ins/TypedArray/prototype/set/typedarray-arg-offset-tointeger.js @@ -84,18 +84,10 @@ testWithTypedArrayConstructors(function(TA) { assert(compareArray(sample, [1, 42]), "[1]"); sample = new TA([1, 2]); - sample.set(src, { - valueOf: function() { - return 1; - } - }); + sample.set(src, { valueOf: function() {return 1;} }); assert(compareArray(sample, [1, 42]), "valueOf"); sample = new TA([1, 2]); - sample.set(src, { - toString: function() { - return 1; - } - }); + sample.set(src, { toString: function() {return 1;} }); assert(compareArray(sample, [1, 42]), "toString"); }); diff --git a/test/built-ins/TypedArray/prototype/slice/speciesctor-get-species-custom-ctor-length-throws.js b/test/built-ins/TypedArray/prototype/slice/speciesctor-get-species-custom-ctor-length-throws.js index 7ff46d746..8d572f230 100644 --- a/test/built-ins/TypedArray/prototype/slice/speciesctor-get-species-custom-ctor-length-throws.js +++ b/test/built-ins/TypedArray/prototype/slice/speciesctor-get-species-custom-ctor-length-throws.js @@ -38,4 +38,4 @@ testWithTypedArrayConstructors(function(TA) { assert.throws(TypeError, function() { sample.slice(); }); -}); +});
\ No newline at end of file diff --git a/test/built-ins/TypedArray/prototype/slice/speciesctor-get-species-custom-ctor-length.js b/test/built-ins/TypedArray/prototype/slice/speciesctor-get-species-custom-ctor-length.js index a4d33b2a9..537b423a2 100644 --- a/test/built-ins/TypedArray/prototype/slice/speciesctor-get-species-custom-ctor-length.js +++ b/test/built-ins/TypedArray/prototype/slice/speciesctor-get-species-custom-ctor-length.js @@ -43,4 +43,4 @@ testWithTypedArrayConstructors(function(TA) { customCount = 5; result = sample.slice(); assert.sameValue(result.length, customCount, "length > count"); -}); +});
\ No newline at end of file diff --git a/test/built-ins/TypedArray/prototype/slice/tointeger-end.js b/test/built-ins/TypedArray/prototype/slice/tointeger-end.js index 13d68874d..2a9be9406 100644 --- a/test/built-ins/TypedArray/prototype/slice/tointeger-end.js +++ b/test/built-ins/TypedArray/prototype/slice/tointeger-end.js @@ -40,7 +40,8 @@ testWithTypedArrayConstructors(function(TA) { assert(compareArray(sample.slice(0, "3"), [40, 41, 42]), "string"); assert( compareArray( - sample.slice(0, obj), [40, 41] + sample.slice(0, obj), + [40, 41] ), "object" ); diff --git a/test/built-ins/TypedArray/prototype/slice/tointeger-start.js b/test/built-ins/TypedArray/prototype/slice/tointeger-start.js index 2f6c2d7cb..f67ee090c 100644 --- a/test/built-ins/TypedArray/prototype/slice/tointeger-start.js +++ b/test/built-ins/TypedArray/prototype/slice/tointeger-start.js @@ -40,7 +40,8 @@ testWithTypedArrayConstructors(function(TA) { assert(compareArray(sample.slice("3"), [43]), "string"); assert( compareArray( - sample.slice(obj), [42, 43] + sample.slice(obj), + [42, 43] ), "object" ); diff --git a/test/built-ins/TypedArray/prototype/some/callbackfn-this.js b/test/built-ins/TypedArray/prototype/some/callbackfn-this.js index 92cc10ad4..d15699b80 100644 --- a/test/built-ins/TypedArray/prototype/some/callbackfn-this.js +++ b/test/built-ins/TypedArray/prototype/some/callbackfn-this.js @@ -27,9 +27,7 @@ includes: [testTypedArray.js] features: [TypedArray] ---*/ -var expected = (function() { - return this; -})(); +var expected = (function() { return this; })(); var thisArg = {}; testWithTypedArrayConstructors(function(TA) { diff --git a/test/built-ins/TypedArray/prototype/some/returns-false-if-every-cb-returns-false.js b/test/built-ins/TypedArray/prototype/some/returns-false-if-every-cb-returns-false.js index bf61d170e..00741adbe 100644 --- a/test/built-ins/TypedArray/prototype/some/returns-false-if-every-cb-returns-false.js +++ b/test/built-ins/TypedArray/prototype/some/returns-false-if-every-cb-returns-false.js @@ -26,7 +26,8 @@ testWithTypedArrayConstructors(function(TA) { [ false, "", - 0, -0, + 0, + -0, NaN, undefined, null diff --git a/test/built-ins/TypedArray/prototype/some/returns-true-if-any-cb-returns-true.js b/test/built-ins/TypedArray/prototype/some/returns-true-if-any-cb-returns-true.js index 113f53f83..c11fdae90 100644 --- a/test/built-ins/TypedArray/prototype/some/returns-true-if-any-cb-returns-true.js +++ b/test/built-ins/TypedArray/prototype/some/returns-true-if-any-cb-returns-true.js @@ -36,9 +36,12 @@ testWithTypedArrayConstructors(function(TA) { "test262", s, {}, - [], -1, - Infinity, -Infinity, - 0.1, -0.1 + [], + -1, + Infinity, + -Infinity, + 0.1, + -0.1 ].forEach(function(val) { var called = 0; var result = sample.some(function() { diff --git a/test/built-ins/TypedArray/prototype/some/this-is-not-typedarray-instance.js b/test/built-ins/TypedArray/prototype/some/this-is-not-typedarray-instance.js index c31d93fc5..acfbe6dbb 100644 --- a/test/built-ins/TypedArray/prototype/some/this-is-not-typedarray-instance.js +++ b/test/built-ins/TypedArray/prototype/some/this-is-not-typedarray-instance.js @@ -22,7 +22,7 @@ features: [TypedArray] ---*/ var some = TypedArray.prototype.some; -var callbackfn = function() {}; +var callbackfn = function () {}; assert.throws(TypeError, function() { some.call({}, callbackfn); diff --git a/test/built-ins/TypedArray/prototype/some/values-are-not-cached.js b/test/built-ins/TypedArray/prototype/some/values-are-not-cached.js index 2c2afb573..c8a3c2cde 100644 --- a/test/built-ins/TypedArray/prototype/some/values-are-not-cached.js +++ b/test/built-ins/TypedArray/prototype/some/values-are-not-cached.js @@ -30,7 +30,7 @@ testWithTypedArrayConstructors(function(TA) { sample.some(function(v, i) { if (i < sample.length - 1) { - sample[i + 1] = 42; + sample[i+1] = 42; } assert.sameValue( diff --git a/test/built-ins/TypedArray/prototype/sort/return-same-instance.js b/test/built-ins/TypedArray/prototype/sort/return-same-instance.js index 23a4312d7..f95885080 100644 --- a/test/built-ins/TypedArray/prototype/sort/return-same-instance.js +++ b/test/built-ins/TypedArray/prototype/sort/return-same-instance.js @@ -20,8 +20,6 @@ testWithTypedArrayConstructors(function(TA) { assert.sameValue(sample, result, "without comparefn"); - result = sample.sort(function() { - return 0; - }); + result = sample.sort(function() { return 0; }); assert.sameValue(sample, result, "with comparefn"); }); diff --git a/test/built-ins/TypedArray/prototype/subarray/return-abrupt-from-begin-symbol.js b/test/built-ins/TypedArray/prototype/subarray/return-abrupt-from-begin-symbol.js index 8b9f5a50e..6da5dd1ba 100644 --- a/test/built-ins/TypedArray/prototype/subarray/return-abrupt-from-begin-symbol.js +++ b/test/built-ins/TypedArray/prototype/subarray/return-abrupt-from-begin-symbol.js @@ -17,7 +17,7 @@ var s = Symbol("1"); testWithTypedArrayConstructors(function(TA) { var sample = new TA(); - + assert.throws(TypeError, function() { sample.subarray(s); }); diff --git a/test/built-ins/TypedArray/prototype/subarray/return-abrupt-from-begin.js b/test/built-ins/TypedArray/prototype/subarray/return-abrupt-from-begin.js index a3343cd46..6e1ac2f64 100644 --- a/test/built-ins/TypedArray/prototype/subarray/return-abrupt-from-begin.js +++ b/test/built-ins/TypedArray/prototype/subarray/return-abrupt-from-begin.js @@ -27,11 +27,11 @@ var o2 = { testWithTypedArrayConstructors(function(TA) { var sample = new TA(); - + assert.throws(Test262Error, function() { sample.subarray(o1); }); - + assert.throws(Test262Error, function() { sample.subarray(o2); }); diff --git a/test/built-ins/TypedArray/prototype/subarray/return-abrupt-from-end.js b/test/built-ins/TypedArray/prototype/subarray/return-abrupt-from-end.js index 4ef1daf2a..eaa4e9ddd 100644 --- a/test/built-ins/TypedArray/prototype/subarray/return-abrupt-from-end.js +++ b/test/built-ins/TypedArray/prototype/subarray/return-abrupt-from-end.js @@ -28,11 +28,11 @@ var o2 = { testWithTypedArrayConstructors(function(TA) { var sample = new TA(); - + assert.throws(Test262Error, function() { sample.subarray(0, o1); }); - + assert.throws(Test262Error, function() { sample.subarray(0, o2); }); diff --git a/test/built-ins/TypedArray/prototype/subarray/tointeger-begin.js b/test/built-ins/TypedArray/prototype/subarray/tointeger-begin.js index 3d38c2080..abf503cb8 100644 --- a/test/built-ins/TypedArray/prototype/subarray/tointeger-begin.js +++ b/test/built-ins/TypedArray/prototype/subarray/tointeger-begin.js @@ -40,7 +40,8 @@ testWithTypedArrayConstructors(function(TA) { assert(compareArray(sample.subarray("3"), [43]), "string"); assert( compareArray( - sample.subarray(obj), [42, 43] + sample.subarray(obj), + [42, 43] ), "object" ); diff --git a/test/built-ins/TypedArray/prototype/subarray/tointeger-end.js b/test/built-ins/TypedArray/prototype/subarray/tointeger-end.js index b59ee07d3..4797bf5b2 100644 --- a/test/built-ins/TypedArray/prototype/subarray/tointeger-end.js +++ b/test/built-ins/TypedArray/prototype/subarray/tointeger-end.js @@ -40,7 +40,8 @@ testWithTypedArrayConstructors(function(TA) { assert(compareArray(sample.subarray(0, "3"), [40, 41, 42]), "string"); assert( compareArray( - sample.subarray(0, obj), [40, 41] + sample.subarray(0, obj), + [40, 41] ), "object" ); |