Backed out 3 changesets (bug 1892041) for causing failures on async-module-does-not...
[gecko.git] / js / src / tests / test262 / built-ins / Set / prototype / intersection / not-a-constructor.js
blob0a8b82b05890e09beb157f5d43bed2c294d688fd
1 // |reftest| skip -- set-methods is not supported
2 // Copyright (C) 2023 Anthony Frehner and Kevin Gibbons. All rights reserved.
3 // This code is governed by the BSD license found in the LICENSE file.
4 /*---
5 esid: sec-set.prototype.intersection
6 description: Set.prototype.intersection does not implement [[Construct]], is not new-able
7 includes: [isConstructor.js]
8 features: [Reflect.construct, set-methods]
9 ---*/
11 assert.sameValue(
12   isConstructor(Set.prototype.intersection),
13   false,
14   "isConstructor(Set.prototype.intersection) must return false"
17 assert.throws(
18   TypeError,
19   () => {
20     new Set.prototype.intersection();
21   },
22   "`new Set.prototype.intersection()` throws TypeError"
25 reportCompare(0, 0);