简体   繁体   English

节点检查器未达到实习生测试的断点

[英]Node Inspector not hitting breakpoint for Intern test

I am trying to debug my intern test using node inspector. 我正在尝试使用节点检查器调试我的内部测试。 I followed all the steps correctly from here . 我从这里正确地遵循了所有步骤。 I gave it a run by performing the following command 我通过执行以下命令来运行它

  1. Start Selenium[for intern test] 开始硒[用于实习测试]
  2. Run the intern test in node environment 在节点环境中运行内部测试

    C:\\node\\node --debug-brk node_modules/intern/runner.js config=tests/intern C:\\ node \\ node --debug-brk node_modules / intern / runner.js config = tests / intern

  3. In another cmd I run the node inspector 在另一个cmd中,我运行节点检查器

    node-inspector --web-port=9999 & 节点检查器--web-port = 9999&

  4. Start the browser 启动浏览器

    http://127.0.0.1:9999/?ws=127.0.0.1:9999&port=5858 http://127.0.0.1:9999/?ws=127.0.0.1:9999&port=5858

I can see all the script of my project. 我可以看到我项目的所有脚本。 I have break point set in one of the test component. 我在测试组件之一中设置了断点。 But the moment I resume the debugger the test start running but the breakpoint is never hit. 但是,当我恢复调试器的那一刻,测试就开始运行,但是断点从未被击中。 What am I doing wrong ? 我究竟做错了什么 ?

I think you should add debugger; 我认为您应该添加debugger; into your script as a break point 进入脚本作为断点

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM