Add more configure options for webdriver path. #3717

Merged
merged 3 commits into from Nov 11, 2016

Projects

None yet

4 participants

@sven-carstens-udg
Contributor

The geckodriver has no option to set the base url. It will only generate failues if used with the default path "/wd/hub". It will work fine if we use the new optional path config option and set it to "/".

@sven-carstens-udg sven-carstens-udg Add more configure options for webdriver path.
Add protocol and path option to easier integrate with the geckodriver and others.
5391163
src/Codeception/Module/WebDriver.php
@@ -285,7 +287,7 @@ public function _requires()
public function _initialize()
{
- $this->wd_host = sprintf('http://%s:%s/wd/hub', $this->config['host'], $this->config['port']);
+ $this->wd_host = sprintf('%s://%s:%s%s', $this->config['protocol'], $this->config['host'], $this->config['port'], $this->config['path'] );
@Nitpick-CI
Nitpick-CI Nov 10, 2016

Expected 0 spaces before closing bracket; 1 found

@sven-carstens-udg sven-carstens-udg Improve PSR-2 code styling.
a3d92c5
@sergeyklay

Could you please return back file mode

100755 → 100644
@sven-carstens-udg sven-carstens-udg Fix wrong file mode.
c86835b
@DavertMik
Member

Thank you!

@DavertMik DavertMik merged commit 84c7712 into Codeception:2.2 Nov 11, 2016

3 checks passed

continuous-integration/appveyor/pr AppVeyor build succeeded
Details
continuous-integration/travis-ci/pr The Travis CI build passed
Details
semaphoreci The build passed on Semaphore.
Details
@sven-carstens-udg sven-carstens-udg deleted the unknown repository branch Nov 11, 2016
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment