Bug 1795082 - Part 2/2: Drop post-processing from getURL() r=zombie
[gecko.git] / js / src / tests / test262 / built-ins / Math / pow / applying-the-exp-operator_A3.js
blobc61fed40d942d94cb00aa7512d7dbaa55f33f01d
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 description: If exponent is −0, the result is 1, even if base is NaN.
6 esid: sec-applying-the-exp-operator
7 ---*/
10 var exponent = -0;
11 var base = new Array();
12 base[0] = -Infinity;
13 base[1] = -1.7976931348623157E308; //largest (by module) finite number
14 base[2] = -0.000000000000001;
15 base[3] = -0;
16 base[4] = +0
17 base[5] = 0.000000000000001;
18 base[6] = 1.7976931348623157E308; //largest finite number
19 base[7] = +Infinity;
20 base[8] = NaN;
21 var basenum = 9;
23 for (var i = 0; i < basenum; i++) {
24   if (Math.pow(base[i], exponent) !== 1) {
25     throw new Test262Error("#1: Math.pow(" + base[i] + ", -0) !== 1");
26   }
29 reportCompare(0, 0);