Merge pull request #1517 from cxielarko/valueof-realm

cross-realm test for BigInt.prototype.valueOf
This commit is contained in:
Rick Waldron 2018-04-18 16:19:49 -04:00 committed by GitHub
commit 119c8eadfa
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 14 additions and 0 deletions

View File

@ -0,0 +1,14 @@
// Copyright 2018 Igalia, S.L. All rights reserved.
// This code is governed by the BSD license found in the LICENSE file.
/*---
esid: sec-bigint.prototype.valueof
description: valueOf called with a BigInt object from another realm
features: [BigInt, cross-realm]
---*/
var other = $262.createRealm().global;
var wrapped = other.Object(other.BigInt(0));
assert.sameValue(BigInt.prototype.valueOf.call(wrapped), 0n,
"cross-realm valueOf");