testng运行卡住

tesng 遇到这种情况是由于host问题,需要修改etc/hosts

ERROR: transport error 202: connect failed: Connection refused

ERROR: JDWP Transport dt_socket failed to initialize, TRANSPORT_INIT(510)

JDWP exit error AGENT_ERROR_TRANSPORT_INIT(197): No transports initialized [../../../src/share/back/debugInit.c:750]

FATAL ERROR in native method: JDWP No transports initialized, jvmtiError=AGENT_ERROR_TRANSPORT_INIT(197)

C:\Windows\system32>ping localhost

Ping request could not find host localhost. Please check the name and try again.

It seams that in some cases DNS is expected to resolve this, and if firewall prevents localhost requests to DNS - stuff breaks. I had to alter hosts file and remove comments in following lines, so I would not rely on DNS for this anymore:

# 127.0.0.1       localhost

# ::1             localhost

猜你喜欢

转载自fengshayage.iteye.com/blog/2360907