tor-browser

The Tor Browser
git clone https://git.dasho.dev/tor-browser.git
Log | Files | Refs | README | LICENSE

compare-array-different-length.js (533B)


      1 // Copyright (C) 2015 the V8 project authors. All rights reserved.
      2 // This code is governed by the BSD license found in the LICENSE file.
      3 
      4 /*---
      5 description: >
      6    Arrays of differing lengths are not equivalent.
      7 includes: [compareArray.js]
      8 ---*/
      9 
     10 
     11 assert.throws(Test262Error, () => {
     12  assert.compareArray([], [undefined]);
     13 }, 'Arrays of differing lengths are not equivalent.');
     14 
     15 assert.throws(Test262Error, () => {
     16  assert.compareArray([undefined], []);
     17 }, 'Arrays of differing lengths are not equivalent.');
     18 
     19 reportCompare(0, 0);