mirror of https://github.com/tc39/test262.git
Add esid to Array/isArray front matter
This commit is contained in:
parent
5ad8dc4219
commit
2f4d0be4b8
|
@ -2,10 +2,11 @@
|
|||
// This code is governed by the BSD license found in the LICENSE file.
|
||||
|
||||
/*---
|
||||
esid: sec-array.isarray
|
||||
es5id: 15.4.3.2-0-1
|
||||
description: Array.isArray must exist as a function
|
||||
---*/
|
||||
|
||||
var f = Array.isArray;
|
||||
var f = Array.isArray;
|
||||
|
||||
assert.sameValue(typeof(f), "function", 'typeof(f)');
|
||||
|
|
|
@ -2,6 +2,7 @@
|
|||
// This code is governed by the BSD license found in the LICENSE file.
|
||||
|
||||
/*---
|
||||
esid: sec-array.isarray
|
||||
es5id: 15.4.3.2-0-2
|
||||
description: Array.isArray must exist as a function taking 1 parameter
|
||||
---*/
|
||||
|
|
|
@ -2,11 +2,12 @@
|
|||
// This code is governed by the BSD license found in the LICENSE file.
|
||||
|
||||
/*---
|
||||
esid: sec-array.isarray
|
||||
es5id: 15.4.3.2-0-3
|
||||
description: Array.isArray return true if its argument is an Array
|
||||
---*/
|
||||
|
||||
var a = [];
|
||||
var b = Array.isArray(a);
|
||||
var a = [];
|
||||
var b = Array.isArray(a);
|
||||
|
||||
assert.sameValue(b, true, 'b');
|
||||
|
|
|
@ -2,17 +2,18 @@
|
|||
// This code is governed by the BSD license found in the LICENSE file.
|
||||
|
||||
/*---
|
||||
esid: sec-array.isarray
|
||||
es5id: 15.4.3.2-0-4
|
||||
description: Array.isArray return false if its argument is not an Array
|
||||
---*/
|
||||
|
||||
var b_num = Array.isArray(42);
|
||||
var b_undef = Array.isArray(undefined);
|
||||
var b_bool = Array.isArray(true);
|
||||
var b_str = Array.isArray("abc");
|
||||
var b_obj = Array.isArray({});
|
||||
var b_null = Array.isArray(null);
|
||||
|
||||
var b_num = Array.isArray(42);
|
||||
var b_undef = Array.isArray(undefined);
|
||||
var b_bool = Array.isArray(true);
|
||||
var b_str = Array.isArray("abc");
|
||||
var b_obj = Array.isArray({});
|
||||
var b_null = Array.isArray(null);
|
||||
|
||||
|
||||
assert.sameValue(b_num, false, 'b_num');
|
||||
assert.sameValue(b_undef, false, 'b_undef');
|
||||
|
|
|
@ -2,12 +2,13 @@
|
|||
// This code is governed by the BSD license found in the LICENSE file.
|
||||
|
||||
/*---
|
||||
esid: sec-array.isarray
|
||||
es5id: 15.4.3.2-0-5
|
||||
description: >
|
||||
Array.isArray return true if its argument is an Array
|
||||
(Array.prototype)
|
||||
---*/
|
||||
|
||||
var b = Array.isArray(Array.prototype);
|
||||
var b = Array.isArray(Array.prototype);
|
||||
|
||||
assert.sameValue(b, true, 'b');
|
||||
|
|
|
@ -2,11 +2,12 @@
|
|||
// This code is governed by the BSD license found in the LICENSE file.
|
||||
|
||||
/*---
|
||||
esid: sec-array.isarray
|
||||
es5id: 15.4.3.2-0-6
|
||||
description: Array.isArray return true if its argument is an Array (new Array())
|
||||
---*/
|
||||
|
||||
var a = new Array(10);
|
||||
var b = Array.isArray(a);
|
||||
var a = new Array(10);
|
||||
var b = Array.isArray(a);
|
||||
|
||||
assert.sameValue(b, true, 'b');
|
||||
|
|
|
@ -2,12 +2,13 @@
|
|||
// This code is governed by the BSD license found in the LICENSE file.
|
||||
|
||||
/*---
|
||||
esid: sec-array.isarray
|
||||
es5id: 15.4.3.2-0-7
|
||||
description: Array.isArray returns false if its argument is not an Array
|
||||
---*/
|
||||
|
||||
var o = new Object();
|
||||
o[12] = 13;
|
||||
var b = Array.isArray(o);
|
||||
var o = new Object();
|
||||
o[12] = 13;
|
||||
var b = Array.isArray(o);
|
||||
|
||||
assert.sameValue(b, false, 'b');
|
||||
|
|
|
@ -2,6 +2,7 @@
|
|||
// This code is governed by the BSD license found in the LICENSE file.
|
||||
|
||||
/*---
|
||||
esid: sec-array.isarray
|
||||
es5id: 15.4.3.2-1-1
|
||||
description: Array.isArray applied to boolean primitive
|
||||
---*/
|
||||
|
|
|
@ -2,6 +2,7 @@
|
|||
// This code is governed by the BSD license found in the LICENSE file.
|
||||
|
||||
/*---
|
||||
esid: sec-array.isarray
|
||||
es5id: 15.4.3.2-1-10
|
||||
description: Array.isArray applied to RegExp object
|
||||
---*/
|
||||
|
|
|
@ -2,6 +2,7 @@
|
|||
// This code is governed by the BSD license found in the LICENSE file.
|
||||
|
||||
/*---
|
||||
esid: sec-array.isarray
|
||||
es5id: 15.4.3.2-1-11
|
||||
description: Array.isArray applied to the JSON object
|
||||
---*/
|
||||
|
|
|
@ -2,6 +2,7 @@
|
|||
// This code is governed by the BSD license found in the LICENSE file.
|
||||
|
||||
/*---
|
||||
esid: sec-array.isarray
|
||||
es5id: 15.4.3.2-1-12
|
||||
description: Array.isArray applied to Error object
|
||||
---*/
|
||||
|
|
|
@ -2,14 +2,15 @@
|
|||
// This code is governed by the BSD license found in the LICENSE file.
|
||||
|
||||
/*---
|
||||
esid: sec-array.isarray
|
||||
es5id: 15.4.3.2-1-13
|
||||
description: Array.isArray applied to Arguments object
|
||||
---*/
|
||||
|
||||
var arg;
|
||||
var arg;
|
||||
|
||||
(function fun() {
|
||||
arg = arguments;
|
||||
}(1, 2, 3));
|
||||
(function fun() {
|
||||
arg = arguments;
|
||||
}(1, 2, 3));
|
||||
|
||||
assert.sameValue(Array.isArray(arg), false, 'Array.isArray(arg)');
|
||||
|
|
|
@ -2,6 +2,7 @@
|
|||
// This code is governed by the BSD license found in the LICENSE file.
|
||||
|
||||
/*---
|
||||
esid: sec-array.isarray
|
||||
es5id: 15.4.3.2-1-15
|
||||
description: Array.isArray applied to the global object
|
||||
---*/
|
||||
|
|
|
@ -2,6 +2,7 @@
|
|||
// This code is governed by the BSD license found in the LICENSE file.
|
||||
|
||||
/*---
|
||||
esid: sec-array.isarray
|
||||
es5id: 15.4.3.2-1-2
|
||||
description: Array.isArray applied to Boolean Object
|
||||
---*/
|
||||
|
|
|
@ -2,6 +2,7 @@
|
|||
// This code is governed by the BSD license found in the LICENSE file.
|
||||
|
||||
/*---
|
||||
esid: sec-array.isarray
|
||||
es5id: 15.4.3.2-1-3
|
||||
description: Array.isArray applied to number primitive
|
||||
---*/
|
||||
|
|
|
@ -2,6 +2,7 @@
|
|||
// This code is governed by the BSD license found in the LICENSE file.
|
||||
|
||||
/*---
|
||||
esid: sec-array.isarray
|
||||
es5id: 15.4.3.2-1-4
|
||||
description: Array.isArray applied to Number object
|
||||
---*/
|
||||
|
|
|
@ -2,6 +2,7 @@
|
|||
// This code is governed by the BSD license found in the LICENSE file.
|
||||
|
||||
/*---
|
||||
esid: sec-array.isarray
|
||||
es5id: 15.4.3.2-1-5
|
||||
description: Array.isArray applied to string primitive
|
||||
---*/
|
||||
|
|
|
@ -2,6 +2,7 @@
|
|||
// This code is governed by the BSD license found in the LICENSE file.
|
||||
|
||||
/*---
|
||||
esid: sec-array.isarray
|
||||
es5id: 15.4.3.2-1-6
|
||||
description: Array.isArray applied to String object
|
||||
---*/
|
||||
|
|
|
@ -2,6 +2,7 @@
|
|||
// This code is governed by the BSD license found in the LICENSE file.
|
||||
|
||||
/*---
|
||||
esid: sec-array.isarray
|
||||
es5id: 15.4.3.2-1-7
|
||||
description: Array.isArray applied to Function object
|
||||
---*/
|
||||
|
|
|
@ -2,6 +2,7 @@
|
|||
// This code is governed by the BSD license found in the LICENSE file.
|
||||
|
||||
/*---
|
||||
esid: sec-array.isarray
|
||||
es5id: 15.4.3.2-1-8
|
||||
description: Array.isArray applied to the Math object
|
||||
---*/
|
||||
|
|
|
@ -2,6 +2,7 @@
|
|||
// This code is governed by the BSD license found in the LICENSE file.
|
||||
|
||||
/*---
|
||||
esid: sec-array.isarray
|
||||
es5id: 15.4.3.2-1-9
|
||||
description: Array.isArray applied to Date object
|
||||
---*/
|
||||
|
|
|
@ -2,14 +2,15 @@
|
|||
// This code is governed by the BSD license found in the LICENSE file.
|
||||
|
||||
/*---
|
||||
esid: sec-array.isarray
|
||||
es5id: 15.4.3.2-2-1
|
||||
description: Array.isArray applied to an object with an array as the prototype
|
||||
---*/
|
||||
|
||||
var proto = [];
|
||||
var Con = function () { };
|
||||
Con.prototype = proto;
|
||||
var proto = [];
|
||||
var Con = function () { };
|
||||
Con.prototype = proto;
|
||||
|
||||
var child = new Con();
|
||||
var child = new Con();
|
||||
|
||||
assert.sameValue(Array.isArray(child), false, 'Array.isArray(child)');
|
||||
|
|
|
@ -2,6 +2,7 @@
|
|||
// This code is governed by the BSD license found in the LICENSE file.
|
||||
|
||||
/*---
|
||||
esid: sec-array.isarray
|
||||
es5id: 15.4.3.2-2-2
|
||||
description: >
|
||||
Array.isArray applied to an object with Array.prototype as the
|
||||
|
|
|
@ -2,6 +2,7 @@
|
|||
// This code is governed by the BSD license found in the LICENSE file.
|
||||
|
||||
/*---
|
||||
esid: sec-array.isarray
|
||||
es5id: 15.4.3.2-2-3
|
||||
description: >
|
||||
Array.isArray applied to an Array-like object with length and some
|
||||
|
|
|
@ -2,6 +2,7 @@
|
|||
// This code is governed by the BSD license found in the LICENSE file.
|
||||
|
||||
/*---
|
||||
esid: sec-array.isarray
|
||||
es6id: 22.1.2.2
|
||||
description: >
|
||||
Array.isArray.name is "isArray".
|
||||
|
|
Loading…
Reference in New Issue