量角器elementExplorer

use*_*391 4 debugging node.js angularjs selenium-webdriver protractor

我正在尝试使用量角器elementExplorer并且不确定为什么我不能这样做(我正在使用Mac).

根据文档 - http://angular.github.io/protractor/#/debugging我要去量角器目录(使用/ local/bin)并输入

node ./bin/elementexplorer.js
Run Code Online (Sandbox Code Playgroud)

我收到以下错误:

module.js:340
throw err;
      ^
Error: Cannot find module '/usr/local/bin/bin/elementexplorer.js'
at Function.Module._resolveFilename (module.js:338:15)
at Function.Module._load (module.js:280:25)
at Function.Module.runMain (module.js:497:10)
at startup (node.js:119:16)
at node.js:902:3
Run Code Online (Sandbox Code Playgroud)

任何帮助?谢谢.

ale*_*cxe 5

你需要cd进入protractor目录:

cd node_modules/protractor
node ./bin/elementexplorer.js
Run Code Online (Sandbox Code Playgroud)

node_modules在你的情况下应该在哪里/usr/local/lib/.