0
1

Delete article

Deleted articles cannot be recovered.

Draft of this article would be also deleted.

Are you sure you want to delete this article?

More than 5 years have passed since last update.

sails.js + mocha でテストしたいのに cannot find module 'sails' って言われたとき (windows)

Posted at

現象

Windows7 の環境で

sails.js のテストを試したとき http://sailsjs.org/#/documentation/concepts/Testing

sails list

もうまくいくのに、

mocha

Cannot find module 'sails'

:anger: と怒られた :angry: ときの話 :cry: 当然

npm list -g

で sails がグローバルにインストールされていることは確認済み :ok:

解決方法

環境変数 NODE_PATH に node_modules のパスを設定した

:angel: 以上 :smile:

参考 :notebook: http://stackoverflow.com/questions/21047030/nodejs-cannot-find-module

0
1
1

Register as a new user and use Qiita more conveniently

  1. You get articles that match your needs
  2. You can efficiently read back useful information
  3. You can use dark theme
What you can do with signing up
0
1

Delete article

Deleted articles cannot be recovered.

Draft of this article would be also deleted.

Are you sure you want to delete this article?