Web Driver Curl Exception

后端 未结 4 954
时光说笑
时光说笑 2021-01-17 21:18

Trying to use Codeception Web Driver and Selenium to emulate ajax through an acceptance test. I was using PhpBrowser but when I was having issues with Ajax my friend suggest

相关标签:
4条回答
  • 2021-01-17 21:49

    I had the same problem, with the exact same error message. For some strange reason, it looked like starting the selenium server from command line did not work.

    My solution turned out to be manually opening the selenium server through Windows Explorer, right click on the file, choose Open with -> Java Platform SE Binary.

    Took me almost 3 hours to figure it out, so I hope this helps somebody.

    0 讨论(0)
  • 2021-01-17 21:56

    I had this problem, and then I remembered that I need to run Xvfb -ac :0 -screen 0 1280x1024x16 & after every Homestead reload (before running Dusk tests).

    Then Dusk works instead of saying:

    Facebook\WebDriver\Exception\WebDriverCurlException: Curl error thrown for http POST to /session with params: {"desiredCapabilities":{"browserName":"chrome","platform":"ANY"}}

    Operation timed out after 30000 milliseconds with 0 bytes received

    See https://stackoverflow.com/a/42630737/470749

    0 讨论(0)
  • 2021-01-17 22:11

    I had this problem and it turned out a new version of Firefox was incompatible with the addon that Selenium uses to communicate with Firefox.

    When you start your tests you should see the new Firefox window appear, and have 30 seconds or so before it goes away again. Within this time, if you type about:addons into the URL field and then click on "Extensions", you should see the "Firefox WebDriver" addon there, and it should be enabled.

    For me it was disabled as it was incompatible with the latest Firefox version. So the solution in this case was to either downgrade Firefox or wait for an updated Selenium.

    Note that the addon is only installed in the Firefox instance under test, so you won't see it when you use Firefox outside of Selenium.

    0 讨论(0)
  • 2021-01-17 22:14

    I had this same problem, I forgot to run phantom.js before trying to do any browser tests. I ran phantomjs and it worked.

    0 讨论(0)
提交回复
热议问题