Debian Codegraph @

js/src/tests/test262/language/expressions/property-accessors/S11.2.1_A4_T8.js

raw
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: Check type of various properties
6 es5id: 11.2.1_A4_T8
7 description: Checking properties of the Math Object
8 ---*/
9
10 //CHECK#1-52
11 if (typeof Math.E !== "number") throw new Test262Error('#1: typeof Math.E === "number". Actual: ' + (typeof Math.E ));
12 if (typeof Math['E'] !== "number") throw new Test262Error('#2: typeof Math["E"] === "number". Actual: ' + (typeof Math["E"] ));
13 if (typeof Math.LN10 !== "number") throw new Test262Error('#3: typeof Math.LN10 === "number". Actual: ' + (typeof Math.LN10 ));
14 if (typeof Math['LN10'] !== "number") throw new Test262Error('#4: typeof Math["LN10"] === "number". Actual: ' + (typeof Math["LN10"] ));
15 if (typeof Math.LN2 !== "number") throw new Test262Error('#5: typeof Math.LN2 === "number". Actual: ' + (typeof Math.LN2 ));
16 if (typeof Math['LN2'] !== "number") throw new Test262Error('#6: typeof Math["LN2"] === "number". Actual: ' + (typeof Math["LN2"] ));
17 if (typeof Math.LOG2E !== "number") throw new Test262Error('#7: typeof Math.LOG2E === "number". Actual: ' + (typeof Math.LOG2E ));
18 if (typeof Math['LOG2E'] !== "number") throw new Test262Error('#8: typeof Math["LOG2E"] === "number". Actual: ' + (typeof Math["LOG2E"] ));
19 if (typeof Math.LOG10E !== "number") throw new Test262Error('#9: typeof Math.LOG10E === "number". Actual: ' + (typeof Math.LOG10E ));
20 if (typeof Math['LOG10E'] !== "number") throw new Test262Error('#10: typeof Math["LOG10E"] === "number". Actual: ' + (typeof Math["LOG10E"] ));
21 if (typeof Math.PI !== "number") throw new Test262Error('#11: typeof Math.PI === "number". Actual: ' + (typeof Math.PI ));
22 if (typeof Math['PI'] !== "number") throw new Test262Error('#12: typeof Math["PI"] === "number". Actual: ' + (typeof Math["PI"] ));
23 if (typeof Math.SQRT1_2 !== "number") throw new Test262Error('#13: typeof Math.SQRT1_2 === "number". Actual: ' + (typeof Math.SQRT1_2 ));
24 if (typeof Math['SQRT1_2'] !== "number") throw new Test262Error('#14: typeof Math["SQRT1_2"] === "number". Actual: ' + (typeof Math["SQRT1_2"] ));
25 if (typeof Math.SQRT2 !== "number") throw new Test262Error('#15: typeof Math.SQRT2 === "number". Actual: ' + (typeof Math.SQRT2 ));
26 if (typeof Math['SQRT2'] !== "number") throw new Test262Error('#16: typeof Math["SQRT2"] === "number". Actual: ' + (typeof Math["SQRT2"] ));
27 if (typeof Math.abs !== "function") throw new Test262Error('#17: typeof Math.abs === "function". Actual: ' + (typeof Math.abs ));
28 if (typeof Math['abs'] !== "function") throw new Test262Error('#18: typeof Math["abs"] === "function". Actual: ' + (typeof Math["abs"] ));
29 if (typeof Math.acos !== "function") throw new Test262Error('#19: typeof Math.acos === "function". Actual: ' + (typeof Math.acos ));
30 if (typeof Math['acos'] !== "function") throw new Test262Error('#20: typeof Math["acos"] === "function". Actual: ' + (typeof Math["acos"] ));
31 if (typeof Math.asin !== "function") throw new Test262Error('#21: typeof Math.asin === "function". Actual: ' + (typeof Math.asin ));
32 if (typeof Math['asin'] !== "function") throw new Test262Error('#22: typeof Math["asin"] === "function". Actual: ' + (typeof Math["asin"] ));
33 if (typeof Math.atan !== "function") throw new Test262Error('#23: typeof Math.atan === "function". Actual: ' + (typeof Math.atan ));
34 if (typeof Math['atan'] !== "function") throw new Test262Error('#24: typeof Math["atan"] === "function". Actual: ' + (typeof Math["atan"] ));
35 if (typeof Math.atan2 !== "function") throw new Test262Error('#25: typeof Math.atan2 === "function". Actual: ' + (typeof Math.atan2 ));
36 if (typeof Math['atan2'] !== "function") throw new Test262Error('#26: typeof Math["atan2"] === "function". Actual: ' + (typeof Math["atan2"] ));
37 if (typeof Math.ceil !== "function") throw new Test262Error('#27: typeof Math.ceil === "function". Actual: ' + (typeof Math.ceil ));
38 if (typeof Math['ceil'] !== "function") throw new Test262Error('#28: typeof Math["ceil"] === "function". Actual: ' + (typeof Math["ceil"] ));
39 if (typeof Math.cos !== "function") throw new Test262Error('#29: typeof Math.cos === "function". Actual: ' + (typeof Math.cos ));
40 if (typeof Math['cos'] !== "function") throw new Test262Error('#30: typeof Math["cos"] === "function". Actual: ' + (typeof Math["cos"] ));
41 if (typeof Math.exp !== "function") throw new Test262Error('#31: typeof Math.exp === "function". Actual: ' + (typeof Math.exp ));
42 if (typeof Math['exp'] !== "function") throw new Test262Error('#32: typeof Math["exp"] === "function". Actual: ' + (typeof Math["exp"] ));
43 if (typeof Math.floor !== "function") throw new Test262Error('#33: typeof Math.floor === "function". Actual: ' + (typeof Math.floor ));
44 if (typeof Math['floor'] !== "function") throw new Test262Error('#34: typeof Math["floor"] === "function". Actual: ' + (typeof Math["floor"] ));
45 if (typeof Math.log !== "function") throw new Test262Error('#35: typeof Math.log === "function". Actual: ' + (typeof Math.log ));
46 if (typeof Math['log'] !== "function") throw new Test262Error('#36: typeof Math["log"] === "function". Actual: ' + (typeof Math["log"] ));
47 if (typeof Math.max !== "function") throw new Test262Error('#37: typeof Math.max === "function". Actual: ' + (typeof Math.max ));
48 if (typeof Math['max'] !== "function") throw new Test262Error('#38: typeof Math["max"] === "function". Actual: ' + (typeof Math["max"] ));
49 if (typeof Math.min !== "function") throw new Test262Error('#39: typeof Math.min === "function". Actual: ' + (typeof Math.min ));
50 if (typeof Math['min'] !== "function") throw new Test262Error('#40: typeof Math["min"] === "function". Actual: ' + (typeof Math["min"] ));
51 if (typeof Math.pow !== "function") throw new Test262Error('#41: typeof Math.pow === "function". Actual: ' + (typeof Math.pow ));
52 if (typeof Math['pow'] !== "function") throw new Test262Error('#42: typeof Math["pow"] === "function". Actual: ' + (typeof Math["pow"] ));
53 if (typeof Math.random !== "function") throw new Test262Error('#43: typeof Math.random === "function". Actual: ' + (typeof Math.random ));
54 if (typeof Math['random'] !== "function") throw new Test262Error('#44: typeof Math["random"] === "function". Actual: ' + (typeof Math["random"] ));
55 if (typeof Math.round !== "function") throw new Test262Error('#45: typeof Math.round === "function". Actual: ' + (typeof Math.round ));
56 if (typeof Math['round'] !== "function") throw new Test262Error('#46: typeof Math["round"] === "function". Actual: ' + (typeof Math["round"] ));
57 if (typeof Math.sin !== "function") throw new Test262Error('#47: typeof Math.sin === "function". Actual: ' + (typeof Math.sin ));
58 if (typeof Math['sin'] !== "function") throw new Test262Error('#48: typeof Math["sin"] === "function". Actual: ' + (typeof Math["sin"] ));
59 if (typeof Math.sqrt !== "function") throw new Test262Error('#49: typeof Math.sqrt === "function". Actual: ' + (typeof Math.sqrt ));
60 if (typeof Math['sqrt'] !== "function") throw new Test262Error('#50: typeof Math["sqrt"] === "function". Actual: ' + (typeof Math["sqrt"] ));
61 if (typeof Math.tan !== "function") throw new Test262Error('#51: typeof Math.tan === "function". Actual: ' + (typeof Math.tan ));
62 if (typeof Math['tan'] !== "function") throw new Test262Error('#52: typeof Math["tan"] === "function". Actual: ' + (typeof Math["tan"] ));
63
64 reportCompare(0, 0);