You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

14 lines
480 B

console.error(__filename);
console.error(module.paths.join('\n')+'\n');
// this should work, and get the one that doesn't throw
require('bar');
// since this is inside a node_modules folder,
// it should be impossible to ever see /node_modules in the
// lookup paths, since it's rooted on the uppermost node_modules
// directory.
require('assert').equal(-1, module.paths.indexOf('/node_modules'));
// this should work, and get the one in ./node_modules/asdf.js
require('asdf');