Sign in
chromium
/
external
/
github.com
/
v8
/
node
/
refs/heads/node-ci-2025-11-20
/
.
/
test
/
parallel
/
test-weakref.js
blob: f8f37bc2ed72d299e9d4bd705fc3eec06fb148b5 [
file
] [
log
] [
blame
] [
edit
]
'use strict'
;
// Flags: --expose-gc
const
common
=
require
(
'../common'
);
const
assert
=
require
(
'assert'
);
const
w
=
new
globalThis
.
WeakRef
({});
setTimeout
(
common
.
mustCall
(()
=>
{
globalThis
.
gc
();
assert
.
strictEqual
(
w
.
deref
(),
undefined
);
}),
200
);