Skip to content
Closed
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
fix lint
  • Loading branch information
David Goldstein committed May 7, 2018
commit 0ec6486a24791315db0270207b1f6095183e966f
8 changes: 5 additions & 3 deletions test/es-module/test-esm-preserve-symlinks-main.js
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ fs.mkdirSync(path.join(tmpDir, 'nested2'));
const entry = path.join(tmpDir, 'nested', 'entry.js');
const entry_link_absolute_path = path.join(tmpDir, 'link.js');
const submodule = path.join(tmpDir, 'nested2', 'submodule.js');
const submodule_link_absolute_path = path.join(tmpDir, 'submodule_link.js')
const submodule_link_absolute_path = path.join(tmpDir, 'submodule_link.js');

fs.writeFileSync(entry, `
const assert = require('assert');
Expand All @@ -40,7 +40,10 @@ function doTest(flags, done) {
// the symlink, and not relative to the symlink target; the file structure set
// up above requires this to not crash when loading ./submodule_link.js
spawn(process.execPath,
flags.concat(['--preserve-symlinks', '--preserve-symlinks-main', entry_link_absolute_path]),
flags.concat([
'--preserve-symlinks',
'--preserve-symlinks-main', entry_link_absolute_path
]),
{ stdio: 'inherit' }).on('exit', (code) => {
assert.strictEqual(code, 0);
done();
Expand All @@ -52,4 +55,3 @@ doTest([], () => {
// now test the new loader
doTest(['--experimental-modules'], () => {});
});