LambdaTest / testcafe-browser-provider-lambdatest

npm Plugin For TestCafe Integration With LambdaTest
https://www.lambdatest.com/
Other
16 stars 22 forks source link

node-tunnel failing in docker Error: Unable to establish one or more of the specified browser connections. #6

Closed grantis closed 2 years ago

grantis commented 4 years ago

Hi guys, Im using testcafe-browser-provider-lambdatest in docker node:12 and it's failing to connect. I believe node-tunnel may be the cause, hopefully you could help.

I'm passing in the appropriate environment variables, username and key and configuration.

NODE_ENV=qa $(npm bin)/testcafe 'lambdatest:Chrome@79.0:Windows 10' scenarios/*.scenario.js

Error message:

Auth succeeded
Checking for updates
Binary already at latest version
Starting tunnel
⠼
⠴
⠼
ERROR Unable to establish one or more of the specified browser connections. This can be caused by network issues or remote device failure.

This issue found me when I ran it in concourse and runs fine locally.

Thank you

prateekLambda commented 4 years ago

Hi @grantis, This is Prateek from LambdaTest. Could you please share your registered email address on LambdaTest? So, we can quickly check the logs of your test.

grantis commented 4 years ago

Hi @prateekLambda , its grant.rigby@spidertracks.co.nz . Sorry for the late response. So I setup something similar with testcafe-browser-provider-browserstack and it appears to have worked so I'm not sure what's happening here.

prateekLambda commented 4 years ago

Hi @grantis I have just dropped you a mail for the issue you have reported.

sduduzog commented 4 years ago

Was this resolved? I just got the same issue with my setup

sduduzog commented 4 years ago

Here's the bit of the logs from my setup

08:54:18 Info | {"status":"SUCCESS","message":"OK"}Tunnel successfully initiated. You can start testing now 09:00:08 Error | { Error: Unable to establish one or more of the specified browser connections. This can be caused by network issues or remote device failure. 09:00:08 Error | at BrowserSet._waitConnectionsOpened (D:\Octopus\Applications\Yumbi Staging 2\yumbi-e2e\0.0.15_3\node_modules\testcafe\src\runner\browser-set.js:83:30) 09:00:08 Error | at Promise.resolve.then (D:\Octopus\Applications\Yumbi Staging 2\yumbi-e2e\0.0.15_3\node_modules\testcafe\src\runner\browser-set.js:106:35) code: 'E1004', data: [] } 10:03:36 Verbose | Process C:\Windows\system32\WindowsPowershell\v1.0\PowerShell.exe in C:\Octopus\Work\20200623065235-56094-6 exited with code -1

dubesar commented 2 years ago

This issue may be caused particularly due to docker environment and not related to testcafe plugin - Check these network docs of Docker here -

  1. https://stackoverflow.com/questions/39512728/cant-connect-to-docker-container-from-outside
  2. https://github.com/coreos/bugs/issues/1936 Its related to docker network. Closing this issue now, feel free to open whenever required if not able to resolve the issue.