Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

npm test errors out with "Error: Cannot find module 'expect.js'" #103

Closed
josephfrazier opened this issue Oct 27, 2015 · 3 comments
Closed
Assignees
Labels

Comments

@josephfrazier
Copy link

I'm having some trouble getting the tests to run successfully. In every version of Node I've tried, I get this error. To illustrate the problem, I set up a travis build demonstrating the issue against this changeset (I can clean up my branch and submit a PR if you're interested in using Travis as well): https://travis-ci.org/joseph-onsip/wascally/builds/87768171

During npm install, I noticed that gulp-spawn-mocha@2.0.2 is deprecated:

npm WARN deprecated gulp-spawn-mocha@2.0.2: Too many changes for a patch version.

Since gulp-spawn-mocha shows up in the stack trace below, perhaps biggulp should use a newer version?

Error: Cannot find module 'expect.js'
    at Function.Module._resolveFilename (module.js:338:15)
    at Function.Module._load (module.js:280:25)
    at Module.require (module.js:364:17)
    at require (module.js:380:17)
    at Object.<anonymous> (/home/travis/build/joseph-onsip/wascally/node_modules/monologue.js/node_modules/riveter/spec/compose.spec.js:6:50)
    at Module._compile (module.js:456:26)
    at Object.Module._extensions..js (module.js:474:10)
    at Module.load (module.js:356:32)
    at Function.Module._load (module.js:312:12)
    at Module.require (module.js:364:17)
    at require (module.js:380:17)
    at /home/travis/build/joseph-onsip/wascally/node_modules/biggulp/node_modules/gulp-spawn-mocha/node_modules/mocha/lib/mocha.js:216:27
    at Array.forEach (native)
    at Mocha.loadFiles (/home/travis/build/joseph-onsip/wascally/node_modules/biggulp/node_modules/gulp-spawn-mocha/node_modules/mocha/lib/mocha.js:213:14)
    at Mocha.run (/home/travis/build/joseph-onsip/wascally/node_modules/biggulp/node_modules/gulp-spawn-mocha/node_modules/mocha/lib/mocha.js:453:10)
    at Object.<anonymous> (/home/travis/build/joseph-onsip/wascally/node_modules/biggulp/node_modules/gulp-spawn-mocha/node_modules/mocha/bin/_mocha:393:18)
    at Module._compile (module.js:456:26)
    at Object.Module._extensions..js (module.js:474:10)
    at Module.load (module.js:356:32)
    at Function.Module._load (module.js:312:12)
    at Function.Module.runMain (module.js:497:10)
    at startup (node.js:119:16)
    at node.js:935:3
@arobson
Copy link
Collaborator

arobson commented Jan 4, 2016

@josephfrazier are you still seeing this error? I've not successfully reproduced it but I know we've also published a few versions since this bug. Let me know if you're still getting this, otherwise, I'll close the issue soon.

@josephfrazier
Copy link
Author

I rebased my travis branch onto the latest master (edc752b), and reproduced the npm test bug here: https://travis-ci.org/josephfrazier/wascally/jobs/100147051#L551.

I was also able to reproduce it locally against master with Node v4.2.4 and npm 2.14.12 by starting up the Vagrant machine, and running npm test

@arobson arobson added bug and removed investigating labels Feb 5, 2016
@arobson arobson added this to the 0.2.11 milestone Feb 5, 2016
@arobson arobson self-assigned this Feb 5, 2016
@arobson arobson removed this from the 0.2.11 milestone Feb 19, 2016
@arobson
Copy link
Collaborator

arobson commented May 2, 2016

@josephfrazier - this issue is corrected in the replacement lib - [rabbot](https://github.com/arobson/rabbot] - which has a very similar API but changes failure semantics because wascally is just too ambitious and can't consistently recover from certain scenarios.

@arobson arobson closed this as completed May 2, 2016
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

2 participants