mirror of
https://github.com/hanzoai/core-js.git
synced 2026-09-24 16:58:15 +00:00
12 lines
296 B
JavaScript
12 lines
296 B
JavaScript
import WeakMap from 'core-js-pure/full/weak-map';
|
|
|
|
QUnit.test('WeakMap.of', assert => {
|
|
const { of } = WeakMap;
|
|
assert.isFunction(of);
|
|
assert.name(of, 'of');
|
|
assert.arity(of, 0);
|
|
const array = [];
|
|
assert.true(of() instanceof WeakMap);
|
|
assert.same(of([array, 2]).get(array), 2);
|
|
});
|