mirror of
https://github.com/tc39/test262.git
synced 2025-07-24 22:45:10 +02:00
harness test: nan.js
Signed-off-by: Rick Waldron <waldron.rick@gmail.com>
This commit is contained in:
parent
7c9b648d08
commit
5f5e1655e1
18
test/harness/nans.js
Normal file
18
test/harness/nans.js
Normal file
@ -0,0 +1,18 @@
|
|||||||
|
// Copyright (C) 2017 Rick Waldron, 2016 the V8 project authors.
|
||||||
|
// This code is governed by the BSD license found in the LICENSE file.
|
||||||
|
/*---
|
||||||
|
description: >
|
||||||
|
Including nans.js will expose:
|
||||||
|
|
||||||
|
var distinctNaNs = [
|
||||||
|
0/0, Infinity/Infinity, -(0/0), Math.pow(-1, 0.5), -Math.pow(-1, 0.5)
|
||||||
|
];
|
||||||
|
|
||||||
|
includes: [nans.js]
|
||||||
|
---*/
|
||||||
|
|
||||||
|
assert.sameValue(isNaN(distinctNaNs[0]), true);
|
||||||
|
assert.sameValue(isNaN(distinctNaNs[1]), true);
|
||||||
|
assert.sameValue(isNaN(distinctNaNs[2]), true);
|
||||||
|
assert.sameValue(isNaN(distinctNaNs[3]), true);
|
||||||
|
assert.sameValue(isNaN(distinctNaNs[4]), true);
|
Loading…
x
Reference in New Issue
Block a user