js/src/tests/test262/ch11/11.7/11.7.2/S11.7.2_A2.1_T1.js

Thu, 15 Jan 2015 15:55:04 +0100

author
Michael Schloh von Bennewitz <michael@schloh.com>
date
Thu, 15 Jan 2015 15:55:04 +0100
branch
TOR_BUG_9701
changeset 9
a63d609f5ebe
permissions
-rw-r--r--

Back out 97036ab72558 which inappropriately compared turds to third parties.

     1 // Copyright 2009 the Sputnik authors.  All rights reserved.
     2 // This code is governed by the BSD license found in the LICENSE file.
     4 /**
     5  * Operator x >> y uses GetValue
     6  *
     7  * @path ch11/11.7/11.7.2/S11.7.2_A2.1_T1.js
     8  * @description Either Type is not Reference or GetBase is not null
     9  */
    11 //CHECK#1
    12 if (-4 >> 1 !== -2) {
    13   $ERROR('#1: -4 >> 1 === -2. Actual: ' + (-4 >> 1));
    14 }
    16 //CHECK#2
    17 var x = -4;
    18 if (x >> 1 !== -2) {
    19   $ERROR('#2: var x = -4; x >> 1 === -2. Actual: ' + (x >> 1));
    20 }
    22 //CHECK#3
    23 var y = 1;
    24 if (-4 >> y !== -2) {
    25   $ERROR('#3: var y = 1; -4 >> y === -2. Actual: ' + (-4 >> y));
    26 }
    28 //CHECK#4
    29 var x = -4;
    30 var y = 1;
    31 if (x >> y !== -2) {
    32   $ERROR('#4: var x = -4; var y = 1; x >> y === -2. Actual: ' + (x >> y));
    33 }
    35 //CHECK#5
    36 var objectx = new Object();
    37 var objecty = new Object();
    38 objectx.prop = -4;
    39 objecty.prop = 1;
    40 if (objectx.prop >> objecty.prop !== -2) {
    41   $ERROR('#5: var objectx = new Object(); var objecty = new Object(); objectx.prop = -4; objecty.prop = 1; objectx.prop >> objecty.prop === -2. Actual: ' + (objectx.prop >> objecty.prop));
    42 }

mercurial