mirror of https://github.com/tc39/test262.git
20 lines
465 B
JavaScript
20 lines
465 B
JavaScript
|
// Copyright (C) 2019 Aleksey Shvayka. All rights reserved.
|
||
|
// This code is governed by the BSD license found in the LICENSE file.
|
||
|
/*---
|
||
|
description: >
|
||
|
verifyProperty uses SameValue for value comparison.
|
||
|
includes: [propertyHelper.js]
|
||
|
---*/
|
||
|
|
||
|
var obj = {
|
||
|
a: NaN,
|
||
|
b: -0,
|
||
|
};
|
||
|
|
||
|
assert(verifyProperty(obj, 'a', { value: NaN }));
|
||
|
assert(verifyProperty(obj, 'b', { value: -0 }));
|
||
|
|
||
|
assert.throws(Test262Error, function() {
|
||
|
verifyProperty(obj, 'b', { value: 0 });
|
||
|
});
|