Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Update WebDriver.php: Minor #123

Merged
merged 1 commit into from
Jul 29, 2024
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
86 changes: 44 additions & 42 deletions src/Codeception/Module/WebDriver.php
Original file line number Diff line number Diff line change
Expand Up @@ -75,7 +75,7 @@
* selenium-standalone start
* ```
*
* Update configuration in `acceptance.suite.yml`:
* Update configuration in `Acceptance.suite.yml`:
*
* ```yaml
* modules:
Expand All @@ -87,7 +87,7 @@
*
* ## Headless Chrome Browser
*
* To enable headless mode (launch tests without showing a window) for Chrome browser using Selenium use this config in `acceptance.suite.yml`:
* To enable headless mode (launch tests without showing a window) for Chrome browser using Selenium use this config in `Acceptance.suite.yml`:
*
* ```yaml
* modules:
Expand Down Expand Up @@ -120,7 +120,7 @@
* * Download and install [ChromeDriver](https://sites.google.com/chromium.org/driver/downloads?authuser=0)
* * Launch ChromeDriver in a separate console window: `chromedriver --url-base=/wd/hub`.
*
* Configuration in `acceptance.suite.yml`:
* Configuration in `Acceptance.suite.yml`:
*
* ```yaml
* modules:
Expand All @@ -144,7 +144,7 @@
* * [GeckoDriver](https://github.com/mozilla/geckodriver/releases) must be installed
* * Start GeckoDriver in a separate console window: `geckodriver`.
*
* Configuration in `acceptance.suite.yml`:
* Configuration in `Acceptance.suite.yml`:
*
* ```yaml
* modules:
Expand Down Expand Up @@ -196,9 +196,9 @@
* 4. If your site is available only locally or via VPN you should use a tunnel app. In this case add `browserstack.local` capability and set it to true.
*
* ```yaml
* modules:
* enabled:
* - WebDriver:
* modules:
* enabled:
* - WebDriver:
* url: http://mysite.com
* host: '<username>:<access key>@hub.browserstack.com'
* port: 80
Expand All @@ -218,19 +218,19 @@
* 4. If your website is available only locally or via VPN you should use LambdaTest tunnel. In this case, you can add capability "tunnel":true;.
*
* ```yaml
* modules:
* enabled:
* - WebDriver:
url: "https://openclassrooms.com"
host: 'hub.lambdatest.com'
port: 80
browser: 'Chrome'
capabilities:
LT:Options:
platformName: 'Windows 10'
browserVersion: 'latest-5'
browserName: 'Chrome'
tunnel: true #for Local testing
* modules:
* enabled:
* - WebDriver:
url: "https://openclassrooms.com"
host: 'hub.lambdatest.com'
port: 80
browser: 'Chrome'
capabilities:
LT:Options:
platformName: 'Windows 10'
browserVersion: 'latest-5'
browserName: 'Chrome'
tunnel: true #for Local testing
* ```
*
* ### TestingBot
Expand All @@ -241,15 +241,15 @@
* 4. Run [TestingBot Tunnel](https://testingbot.com/support/other/tunnel) if your site can't be accessed from Internet
*
* ```yaml
* modules:
* enabled:
* - WebDriver:
* url: http://mysite.com
* host: '<key>:<secret>@hub.testingbot.com'
* port: 80
* browser: chrome
* capabilities:
* platformName: Windows 10
* modules:
* enabled:
* - WebDriver:
* url: http://mysite.com
* host: '<key>:<secret>@hub.testingbot.com'
* port: 80
* browser: chrome
* capabilities:
* platformName: Windows 10
* ```
*
* ## Configuration
Expand All @@ -276,19 +276,19 @@
* * `webdriver_proxy` - sets http proxy to tunnel requests to the remote Selenium WebDriver through
* * `webdriver_proxy_port` - sets http proxy server port to tunnel requests to the remote Selenium WebDriver through
*
* Example (`acceptance.suite.yml`)
* Example (`Acceptance.suite.yml`)
*
* ```yaml
* modules:
* enabled:
* - WebDriver:
* url: 'http://localhost/'
* browser: firefox
* window_size: 1024x768
* capabilities:
* unhandledPromptBehaviour: 'accept'
* moz:firefoxOptions:
* profile: '~/firefox-profiles/codeception-profile.zip.b64'
* modules:
* enabled:
* - WebDriver:
* url: 'http://localhost/'
* browser: firefox
* window_size: 1024x768
* capabilities:
* unhandledPromptBehaviour: 'accept'
* moz:firefoxOptions:
* profile: '~/firefox-profiles/codeception-profile.zip.b64'
* ```
*
* ## Loading Parts from other Modules
Expand Down Expand Up @@ -356,7 +356,8 @@
*
* You can inject `\Codeception\Scenario` into your test to get information about the current configuration:
* ```php
* use Codeception\Scenario
* use Codeception\Scenario;
*
* public function myTest(AcceptanceTester $I, Scenario $scenario)
* {
* if ('firefox' === $scenario->current('browser')) {
Expand Down Expand Up @@ -522,7 +523,8 @@ public function _initialize()
* This is how it can be done via `_capabilities` method from `Helper\Acceptance`:
*
* ```php
* <?php // inside Helper\Acceptance
* <?php
* // inside Helper\Acceptance
* public function _before(TestInterface $test)
* {
* $name = $test->getMetadata()->getName();
Expand Down
Loading