tor-browser

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

primitive-numbers.js (717B)


      1 // Copyright (C) 2015 Jordan Harband. All rights reserved.
      2 // This code is governed by the BSD license found in the LICENSE file.
      3 
      4 /*---
      5 esid: sec-object.values
      6 description: Object.values accepts number primitives.
      7 author: Jordan Harband
      8 ---*/
      9 
     10 assert.sameValue(Object.values(0).length, 0, '0 has zero values');
     11 assert.sameValue(Object.values(-0).length, 0, '-0 has zero values');
     12 assert.sameValue(Object.values(Infinity).length, 0, 'Infinity has zero values');
     13 assert.sameValue(Object.values(-Infinity).length, 0, '-Infinity has zero values');
     14 assert.sameValue(Object.values(NaN).length, 0, 'NaN has zero values');
     15 assert.sameValue(Object.values(Math.PI).length, 0, 'Math.PI has zero values');
     16 
     17 reportCompare(0, 0);