So I used git to clone Twitter Bootstrap. Then I got node.js and npm, because I was following the directions here: https://github.com/twbs/bootstrap Then I ran the command npm install recess connect uglify-js jshint -g
. I also then installed phantomjs in the same manner (first without the -g
flag and then with it). Now I am supposed to be able to run make
and then make test
. make
worked fine for me, but make test
is throwing the following error:
jshint js/*.js --config js/.jshintrc
jshint js/tests/unit/*.js --config js/.jshintrc
node js/tests/server.js &
phantomjs js/tests/phantom.js "http://localhost:3000/js/tests"
module.js:340
throw err;
^
Error: Cannot find module 'connect'
at Function.Module._resolveFilename (module.js:338:15)
at Function.Module._load (module.js:280:25)
at Module.require (module.js:362:17)
at require (module.js:378:17)
at Object.<anonymous> (/Users/Jon/dev/blossom/bootstrap/js/tests/server.js:6:15)
at Module._compile (module.js:449:26)
at Object.Module._extensions..js (module.js:467:10)
at Module.load (module.js:356:32)
at Function.Module._load (module.js:312:12)
at Module.runMain (module.js:492:10)
Unable to access network
kill -9 `cat js/tests/pid.txt`
cat: js/tests/pid.txt: No such file or directory
kill: usage: kill [-s sigspec | -n signum | -sigspec] pid | jobspec ... or kill -l [sigspec]
make: *** [test] Error 1
A bit late, but for the record:
Run the nmp install
line without the -g
switch. The -g
switch tells npm to install globally, and globally installed modules are not picked up by the module loader when running an application. Globally installing modules is to have access to the commands a module may provide (like the phantomjs
or jshint
you see in that trace).