1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42
|
// Copyright 2009 the Sputnik authors. All rights reserved.
// This code is governed by the BSD license found in the LICENSE file.
/**
* Applaing negation to boolean works well
*
* @path ch08/8.3/S8.3_A3.js
* @description Check not false equals true, not true equals false
*/
//////////////////////////////////////////////////////////////////////////////
//CHECK#1
if (!false !== true){
$ERROR('#1: !false === true');
}
//
//////////////////////////////////////////////////////////////////////////////
//////////////////////////////////////////////////////////////////////////////
//CHECK#2
if (!false != true){
$ERROR('#2: !false == true');
}
//
//////////////////////////////////////////////////////////////////////////////
//////////////////////////////////////////////////////////////////////////////
//CHECK#3
if (!true !== false){
$ERROR('#3: !true === false');
}
//
//////////////////////////////////////////////////////////////////////////////
//////////////////////////////////////////////////////////////////////////////
//CHECK#4
if (!true != false){
$ERROR('#4: !true == false');
}
//
//////////////////////////////////////////////////////////////////////////////
|