Debian Codegraph @

js/src/tests/test262/built-ins/Array/from/this-null.js

raw
1 // Copyright 2015 Leonardo Balter. All rights reserved.
2 // This code is governed by the license found in the LICENSE file.
3 /*---
4 esid: sec-array.from
5 es6id: 22.1.2.1
6 description: Does not throw if this is null
7 ---*/
8
9 var result = Array.from.call(null, []);
10
11 assert(result instanceof Array, 'The result of evaluating (result instanceof Array) is expected to be true');
12 assert.sameValue(result.length, 0, 'The value of result.length is expected to be 0');
13
14 reportCompare(0, 0);