js/src/tests/test262/ch11/11.8/11.8.6/S11.8.6_A5_T1.js

Wed, 31 Dec 2014 13:27:57 +0100

author
Michael Schloh von Bennewitz <michael@schloh.com>
date
Wed, 31 Dec 2014 13:27:57 +0100
branch
TOR_BUG_3246
changeset 6
8bccb770b82d
permissions
-rw-r--r--

Ignore runtime configuration files generated during quality assurance.

     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  * TypeError is subclass of Error from instanceof operator point of view
     6  *
     7  * @path ch11/11.8/11.8.6/S11.8.6_A5_T1.js
     8  * @description Checking Error case
     9  */
    11 var __err = new Error;
    13 //////////////////////////////////////////////////////////////////////////////
    14 //CHECK#1
    15 if (!(__err instanceof Error)) {
    16 	$ERROR('#1: TypeError is subclass of Error from instanceof operator poit of view');
    17 }
    18 //
    19 //////////////////////////////////////////////////////////////////////////////
    21 //////////////////////////////////////////////////////////////////////////////
    22 //CHECK#2
    23 if (__err instanceof TypeError) {
    24 	$ERROR('#2: TypeError is subclass of Error from instanceof operator poit of view');
    25 }
    26 //
    27 //////////////////////////////////////////////////////////////////////////////
    29 var err__ = Error('failed');
    31 //////////////////////////////////////////////////////////////////////////////
    32 //CHECK#3
    33 if (!(err__ instanceof Error)) {
    34 	$ERROR('#3: TypeError is subclass of Error from instanceof operator poit of view');
    35 }
    36 //
    37 //////////////////////////////////////////////////////////////////////////////
    39 //////////////////////////////////////////////////////////////////////////////
    40 //CHECK#4
    41 if (err__ instanceof TypeError) {
    42 	$ERROR('#4: TypeError is subclass of Error from instanceof operator poit of view');
    43 }
    44 //
    45 //////////////////////////////////////////////////////////////////////////////

mercurial