summaryrefslogtreecommitdiff
path: root/Libraries/LibJS/Tests/Array.js
blob: 519bb54d8b6416a2bc6e4e56810b4cfd92f70967 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
try {
    assert(Array.length === 1);
    assert(Array.prototype.length === 0);
    assert(typeof Array() === "object");
    assert(typeof new Array() === "object");

    x = new Array(5);

    assert(x.length === 5);

    console.log("PASS");
} catch (e) {
    console.log("FAIL: " + e.message);
}