tor-browser

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

S15.9.3.2_A1_T1.js (4752B)


      1 // Copyright 2009 the Sputnik authors.  All rights reserved.
      2 // This code is governed by the BSD license found in the LICENSE file.
      3 
      4 /*---
      5 info: |
      6    When Date is called as part of a new expression it is
      7    a constructor: it initialises the newly created object
      8 esid: sec-date-value
      9 description: Checking types of newly created objects and it values
     10 includes: [dateConstants.js]
     11 ---*/
     12 assert.sameValue(
     13  typeof new Date(date_1899_end),
     14  "object",
     15  'The value of `typeof new Date(date_1899_end)` is expected to be "object"'
     16 );
     17 
     18 assert.notSameValue(new Date(date_1899_end), undefined, 'new Date(date_1899_end) is expected to not equal ``undefined``');
     19 
     20 var x13 = new Date(date_1899_end);
     21 assert.sameValue(typeof x13, "object", 'The value of `typeof x13` is expected to be "object"');
     22 
     23 var x14 = new Date(date_1899_end);
     24 assert.notSameValue(x14, undefined, 'The value of x14 is expected to not equal ``undefined``');
     25 
     26 assert.sameValue(
     27  typeof new Date(date_1900_start),
     28  "object",
     29  'The value of `typeof new Date(date_1900_start)` is expected to be "object"'
     30 );
     31 
     32 assert.notSameValue(
     33  new Date(date_1900_start),
     34  undefined,
     35  'new Date(date_1900_start) is expected to not equal ``undefined``'
     36 );
     37 
     38 var x23 = new Date(date_1900_start);
     39 assert.sameValue(typeof x23, "object", 'The value of `typeof x23` is expected to be "object"');
     40 
     41 var x24 = new Date(date_1900_start);
     42 assert.notSameValue(x24, undefined, 'The value of x24 is expected to not equal ``undefined``');
     43 
     44 assert.sameValue(
     45  typeof new Date(date_1969_end),
     46  "object",
     47  'The value of `typeof new Date(date_1969_end)` is expected to be "object"'
     48 );
     49 
     50 assert.notSameValue(new Date(date_1969_end), undefined, 'new Date(date_1969_end) is expected to not equal ``undefined``');
     51 
     52 var x33 = new Date(date_1969_end);
     53 assert.sameValue(typeof x33, "object", 'The value of `typeof x33` is expected to be "object"');
     54 
     55 var x34 = new Date(date_1969_end);
     56 assert.notSameValue(x34, undefined, 'The value of x34 is expected to not equal ``undefined``');
     57 
     58 assert.sameValue(
     59  typeof new Date(date_1970_start),
     60  "object",
     61  'The value of `typeof new Date(date_1970_start)` is expected to be "object"'
     62 );
     63 
     64 assert.notSameValue(
     65  new Date(date_1970_start),
     66  undefined,
     67  'new Date(date_1970_start) is expected to not equal ``undefined``'
     68 );
     69 
     70 var x43 = new Date(date_1970_start);
     71 assert.sameValue(typeof x43, "object", 'The value of `typeof x43` is expected to be "object"');
     72 
     73 var x44 = new Date(date_1970_start);
     74 assert.notSameValue(x44, undefined, 'The value of x44 is expected to not equal ``undefined``');
     75 
     76 assert.sameValue(
     77  typeof new Date(date_1999_end),
     78  "object",
     79  'The value of `typeof new Date(date_1999_end)` is expected to be "object"'
     80 );
     81 
     82 assert.notSameValue(new Date(date_1999_end), undefined, 'new Date(date_1999_end) is expected to not equal ``undefined``');
     83 
     84 var x53 = new Date(date_1999_end);
     85 assert.sameValue(typeof x53, "object", 'The value of `typeof x53` is expected to be "object"');
     86 
     87 var x54 = new Date(date_1999_end);
     88 assert.notSameValue(x54, undefined, 'The value of x54 is expected to not equal ``undefined``');
     89 
     90 assert.sameValue(
     91  typeof new Date(date_2000_start),
     92  "object",
     93  'The value of `typeof new Date(date_2000_start)` is expected to be "object"'
     94 );
     95 
     96 assert.notSameValue(
     97  new Date(date_2000_start),
     98  undefined,
     99  'new Date(date_2000_start) is expected to not equal ``undefined``'
    100 );
    101 
    102 var x63 = new Date(date_2000_start);
    103 assert.sameValue(typeof x63, "object", 'The value of `typeof x63` is expected to be "object"');
    104 
    105 var x64 = new Date(date_2000_start);
    106 assert.notSameValue(x64, undefined, 'The value of x64 is expected to not equal ``undefined``');
    107 
    108 assert.sameValue(
    109  typeof new Date(date_2099_end),
    110  "object",
    111  'The value of `typeof new Date(date_2099_end)` is expected to be "object"'
    112 );
    113 
    114 assert.notSameValue(new Date(date_2099_end), undefined, 'new Date(date_2099_end) is expected to not equal ``undefined``');
    115 
    116 var x73 = new Date(date_2099_end);
    117 assert.sameValue(typeof x73, "object", 'The value of `typeof x73` is expected to be "object"');
    118 
    119 var x74 = new Date(date_2099_end);
    120 assert.notSameValue(x74, undefined, 'The value of x74 is expected to not equal ``undefined``');
    121 
    122 assert.sameValue(
    123  typeof new Date(date_2100_start),
    124  "object",
    125  'The value of `typeof new Date(date_2100_start)` is expected to be "object"'
    126 );
    127 
    128 assert.notSameValue(
    129  new Date(date_2100_start),
    130  undefined,
    131  'new Date(date_2100_start) is expected to not equal ``undefined``'
    132 );
    133 
    134 var x83 = new Date(date_2100_start);
    135 assert.sameValue(typeof x83, "object", 'The value of `typeof x83` is expected to be "object"');
    136 
    137 var x84 = new Date(date_2100_start);
    138 assert.notSameValue(x84, undefined, 'The value of x84 is expected to not equal ``undefined``');
    139 
    140 reportCompare(0, 0);