Skip to content

Commit c6aadc7

Browse files
committed
Apply review feedback
1 parent ef8c2a6 commit c6aadc7

11 files changed

+35
-38
lines changed

test/built-ins/FinalizationGroup/constructor.js

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -6,6 +6,7 @@ esid: sec-finalization-group-constructor
66
description: >
77
The FinalizationGroup constructor is the %FinalizationGroup% intrinsic object and the initial
88
value of the FinalizationGroup property of the global object.
9+
features: [FinalizationGroup]
910
---*/
1011

1112
assert.sameValue(

test/built-ins/FinalizationGroup/instance-extensible.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -23,7 +23,7 @@ info: |
2323
4. Set obj.[[Prototype]] to proto.
2424
5. Set obj.[[Extensible]] to true.
2525
6. Return obj.
26-
features: [FinalizationGroup, Reflect]
26+
features: [FinalizationGroup]
2727
---*/
2828

2929
var fg = new FinalizationGroup(function() {});

test/built-ins/FinalizationGroup/prototype-from-newtarget-abrupt.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -38,4 +38,4 @@ assert.throws(Test262Error, function() {
3838
Reflect.construct(FinalizationGroup, [function() {}], newTarget);
3939
});
4040

41-
assert.sameValue(calls, 1);
41+
assert.sameValue(calls, 1);

test/built-ins/FinalizationGroup/prototype/cleanupSome/callback-not-callable-throws.js

Lines changed: 8 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -20,38 +20,34 @@ assert.sameValue(typeof FinalizationGroup.prototype.cleanupSome, 'function');
2020
var fg = new FinalizationGroup(function() {});
2121

2222
assert.throws(TypeError, function() {
23-
fg(undefined);
24-
}, 'undefined');
25-
26-
assert.throws(TypeError, function() {
27-
fg(null);
23+
fg.cleanupSome(null);
2824
}, 'null');
2925

3026
assert.throws(TypeError, function() {
31-
fg(true);
27+
fg.cleanupSome(true);
3228
}, 'true');
3329

3430
assert.throws(TypeError, function() {
35-
fg(false);
31+
fg.cleanupSome(false);
3632
}, 'false');
3733

3834
assert.throws(TypeError, function() {
39-
fg(1);
35+
fg.cleanupSome(1);
4036
}, 'number');
4137

4238
assert.throws(TypeError, function() {
43-
fg('object');
39+
fg.cleanupSome('object');
4440
}, 'string');
4541

4642
var s = Symbol();
4743
assert.throws(TypeError, function() {
48-
fg(s);
44+
fg.cleanupSome(s);
4945
}, 'symbol');
5046

5147
assert.throws(TypeError, function() {
52-
fg({});
48+
fg.cleanupSome({});
5349
}, 'object');
5450

5551
assert.throws(TypeError, function() {
56-
fg(FinalizationGroup.prototype);
52+
fg.cleanupSome(FinalizationGroup.prototype);
5753
}, 'FinalizationGroup.prototype');

test/built-ins/FinalizationGroup/prototype/cleanupSome/return-undefined.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,7 @@ info: |
1313
4. If callback is not undefined and IsCallable(callback) is false, throw a TypeError exception.
1414
5. Perform ! CleanupFinalizationGroup(finalizationGroup, callback).
1515
6. Return undefined.
16-
features: [FinalizationGroup]
16+
features: [FinalizationGroup, arrow-function, async-functions, async-iteration, class]
1717
---*/
1818

1919
var fn = function() {};

test/built-ins/FinalizationGroup/prototype/register/length.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -26,7 +26,7 @@ features: [FinalizationGroup]
2626

2727
verifyProperty(FinalizationGroup.prototype.register, 'length', {
2828
value: 2,
29-
writable: false,
3029
enumerable: false,
30+
writable: false,
3131
configurable: true
3232
});

test/built-ins/FinalizationGroup/prototype/register/name.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -25,7 +25,7 @@ features: [FinalizationGroup]
2525

2626
verifyProperty(FinalizationGroup.prototype.register, 'name', {
2727
value: 'register',
28-
writable: false,
2928
enumerable: false,
29+
writable: false,
3030
configurable: true
3131
});

test/built-ins/FinalizationGroup/prototype/register/target-not-object-throws.js

Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -23,30 +23,30 @@ assert.sameValue(typeof FinalizationGroup.prototype.register, 'function');
2323
var fg = new FinalizationGroup(function() {});
2424

2525
assert.throws(TypeError, function() {
26-
fg(undefined);
26+
fg.register(undefined);
2727
}, 'undefined');
2828

2929
assert.throws(TypeError, function() {
30-
fg(null);
30+
fg.register(null);
3131
}, 'null');
3232

3333
assert.throws(TypeError, function() {
34-
fg(true);
34+
fg.register(true);
3535
}, 'true');
3636

3737
assert.throws(TypeError, function() {
38-
fg(false);
38+
fg.register(false);
3939
}, 'false');
4040

4141
assert.throws(TypeError, function() {
42-
fg(1);
42+
fg.register(1);
4343
}, 'number');
4444

4545
assert.throws(TypeError, function() {
46-
fg('object');
46+
fg.register('object');
4747
}, 'string');
4848

4949
var s = Symbol();
5050
assert.throws(TypeError, function() {
51-
fg(s);
51+
fg.register(s);
5252
}, 'symbol');

test/built-ins/FinalizationGroup/prototype/register/unregisterToken-not-object-or-undefined-throws.js

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -23,26 +23,26 @@ var fg = new FinalizationGroup(function() {});
2323
var target = {};
2424

2525
assert.throws(TypeError, function() {
26-
fg(target, undefined, null);
26+
fg.register(target, undefined, null);
2727
}, 'null');
2828

2929
assert.throws(TypeError, function() {
30-
fg(target, undefined, true);
30+
fg.register(target, undefined, true);
3131
}, 'true');
3232

3333
assert.throws(TypeError, function() {
34-
fg(target, undefined, false);
34+
fg.register(target, undefined, false);
3535
}, 'false');
3636

3737
assert.throws(TypeError, function() {
38-
fg(target, undefined, 1);
38+
fg.register(target, undefined, 1);
3939
}, 'number');
4040

4141
assert.throws(TypeError, function() {
42-
fg(target, undefined, 'object');
42+
fg.register(target, undefined, 'object');
4343
}, 'string');
4444

4545
var s = Symbol();
4646
assert.throws(TypeError, function() {
47-
fg(target, undefined, s);
47+
fg.register(target, undefined, s);
4848
}, 'symbol');

test/built-ins/FinalizationGroup/prototype/unregister/unregisterToken-not-object-throws.js

Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -20,30 +20,30 @@ assert.sameValue(typeof FinalizationGroup.prototype.unregister, 'function');
2020
var fg = new FinalizationGroup(function() {});
2121

2222
assert.throws(TypeError, function() {
23-
fg(undefined);
23+
fg.unregister(undefined);
2424
}, 'undefined');
2525

2626
assert.throws(TypeError, function() {
27-
fg(null);
27+
fg.unregister(null);
2828
}, 'null');
2929

3030
assert.throws(TypeError, function() {
31-
fg(true);
31+
fg.unregister(true);
3232
}, 'true');
3333

3434
assert.throws(TypeError, function() {
35-
fg(false);
35+
fg.unregister(false);
3636
}, 'false');
3737

3838
assert.throws(TypeError, function() {
39-
fg(1);
39+
fg.unregister(1);
4040
}, 'number');
4141

4242
assert.throws(TypeError, function() {
43-
fg('object');
43+
fg.unregister('object');
4444
}, 'string');
4545

4646
var s = Symbol();
4747
assert.throws(TypeError, function() {
48-
fg(s);
48+
fg.unregister(s);
4949
}, 'symbol');

0 commit comments

Comments
 (0)