title: Run Nodejs program that ignores parent node_modules
body: <p>I have a library and I want to test it by doing a full install locally before publishing to npm. One of the things I want to test is if all the dependencies are part of the project. Because of how nodejs structures its module system though, (<a href="https://nodejs.org/dist/latest-v12.x/docs/api/all.html#modules_loading_from_node_modules_folders" rel="noreferrer">a nodejs module is searched for at every directory level</a>) I do not have a good way to ensure that the module I am requiring came from the current folder's node_modules, and not the parent folder's node_modules.</p>
  
  <p>Here is the project structure:</p>
  
  <pre><code>library-folder/
    package.json
    node_modules/
    testing/integration/
      package.json
      node_modules/
      test-install.js
  </code></pre>
  
  <p>I want to know if there is a way to tell nodejs to only require modules from the current directory, and ignore any parent directories.</p>