2017-06-06 02:44:56 +02:00
|
|
|
// Flags: --experimental-modules
|
2018-08-28 17:28:46 +02:00
|
|
|
import '../common/index.mjs';
|
2017-06-06 02:44:56 +02:00
|
|
|
import * as fs from 'fs';
|
|
|
|
import assert from 'assert';
|
2018-04-23 01:56:42 +02:00
|
|
|
import Module from 'module';
|
2017-06-06 02:44:56 +02:00
|
|
|
|
2018-04-23 01:56:42 +02:00
|
|
|
const keys = Object.entries(
|
|
|
|
Object.getOwnPropertyDescriptors(new Module().require('fs')))
|
2018-12-19 01:05:06 +01:00
|
|
|
.filter(([ , d]) => d.enumerable)
|
2018-04-23 01:56:42 +02:00
|
|
|
.map(([name]) => name)
|
|
|
|
.concat('default')
|
|
|
|
.sort();
|
|
|
|
|
2019-06-28 23:53:17 +02:00
|
|
|
assert.deepStrictEqual(keys, Object.keys(fs).sort());
|