mirror of
https://github.com/nodejs/node.git
synced 2025-05-20 19:24:39 +00:00

PR-URL: https://github.com/nodejs/node/pull/34552 Reviewed-By: James M Snell <jasnell@gmail.com>
26 lines
554 B
JavaScript
26 lines
554 B
JavaScript
'use strict';
|
|
|
|
const common = require('../common');
|
|
if (!common.hasCrypto)
|
|
common.skip('missing crypto');
|
|
|
|
const fixtures = require('../common/fixtures');
|
|
|
|
const assert = require('assert');
|
|
const { spawnSync } = require('child_process');
|
|
|
|
const dep = fixtures.path('policy', 'main.mjs');
|
|
{
|
|
const depPolicy = fixtures.path(
|
|
'policy',
|
|
'dependencies',
|
|
'dependencies-scopes-policy.json');
|
|
const { status } = spawnSync(
|
|
process.execPath,
|
|
[
|
|
'--experimental-policy', depPolicy, dep,
|
|
]
|
|
);
|
|
assert.strictEqual(status, 0);
|
|
}
|