gpt4 book ai didi

node.js/karma/end-to-end testing : failed to proxy/app/index. html(错误:connect ECONNREFUSED)

转载 作者:搜寻专家 更新时间:2023-10-31 22:28:08 24 4
gpt4 key购买 nike

以下是我在尝试从 AngularJS 教程 http://docs.angularjs.org/tutorial/step_05 运行端到端测试时收到的消息在 MS Windows 8 专业版上。您能告诉我怎样才能使这个测试运行良好吗?

[2013-06-10 17:27:54.100] [WARN] config - "/" is proxied, you should probably change urlRoot to avoid conflicts
INFO [karma]: Karma server started at http://localhost:9876/
INFO [launcher]: <<< Starting browser Chrome
INFO [launcher]: --- Starting browser Chrome
INFO [Chrome 27.0 (Windows)]: Connected on socket id E20UigDmDqhk3jaRRYAP
WARN [proxy]: failed to proxy /app/index.html (Error: connect ECONNREFUSED)

ECONNREFUSED while running end-to-end test using Karma node.js package on MS Windows 8 Professional

最佳答案

您看到的错误表明您还没有启动网络服务器。由于您正在使用 ./scripts/e2e-test.sh 来运行您的 e2e 测试,因此您需要让您的网络服务器从 localhost:8000 为应用程序提供服务,并且 docroot 需要指向 angular-phonecat 文件夹,而不是 app 文件夹。这可以通过简单地运行 ./scripts/web-server.js 来完成(参见 step-00 )

请注意,还有第二种方法可以运行端到端测试。你可以访问

http://localhost:8000/test/e2e/runner.html 

关于node.js/karma/end-to-end testing : failed to proxy/app/index. html(错误:connect ECONNREFUSED),我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/17025210/

24 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com