Cannot test due to HTML files in node_modules

When running meteor test --driver-package practicalmeteor:mocha, I get this error:

  While processing files with static-html (for target web.browser):
  node_modules/jsforce/test/browser/client.test.html:1: Can't set DOCTYPE
  here.  (Meteor sets <!DOCTYPE html> for you)

If I remove that file it works OK, but is it possible to not attempt to compile the files inside of node_modules?

I’ve been able to re-create the same issue:

  1. meteor create jsforce-test
  2. meteor npm install --save jsforce
  3. meteor test --driver-package practicalmeteor:mocha --port 3100

I then get the error during startup. Looks like a bug to me. I’d suggest opening a new issue with a small repro that follows the above steps.