mink / webdriver-classic-driver
W3C WebDriver Classic driver for Mink framework
Installs: 5 481
Dependents: 1
Suggesters: 0
Security: 0
Stars: 3
Watchers: 6
Forks: 5
Open Issues: 10
Language:JavaScript
Type:mink-driver
Requires
- php: >=7.4
- ext-json: *
- behat/mink: ^1.11@dev
- php-webdriver/webdriver: ^1.14
Requires (Dev)
- jetbrains/phpstorm-attributes: ^1.0
- mink/driver-testsuite: dev-master
- phpstan/phpstan: ^1.10
- phpstan/phpstan-phpunit: ^1.3
- phpunit/phpunit: ^9.6.8
- symfony/error-handler: ^5.4 || ^6.0 || ^7.0
- symfony/process: ^5.4 || ^6.0 || ^7.0
- dev-main / 1.x-dev
- 1.0.0
- dev-chore/support-old-page-timeout
- dev-bugfix/investigate-crash
- dev-chore/support-old-page-timeout-fix
- dev-chore/simplify-custom-tests
- dev-chore/optimize-build-matrix
- dev-bugfix/persist-original-browser-name
- dev-chore/improve-test-coverage
- dev-chore/improve-test-port-handling
- dev-chore/improve-readme
- dev-bugfix/fix-gettext
- dev-remove-syn
This package is auto-updated.
Last update: 2024-11-05 06:56:15 UTC
README
Usage Example
<?php use Behat\Mink\Mink, Behat\Mink\Session, Mink\WebdriverClassicDriver\WebdriverClassicDriver; require_once __DIR__ . '/vendor/autoload.php'; $browserName = 'firefox'; $url = 'http://example.com'; $mink = new Mink(array( 'webdriver-classic' => new Session(new WebdriverClassicDriver($browserName)), )); $session = $mink->getSession('webdriver-classic'); $session->visit($url); $session->getPage()->findLink('Chat')->click();
Please refer to MinkExtension-example for an executable example.
Installation
composer require behat/mink mink/webdriver-classic-driver
Testing
- Start WebDriver
- If you have Docker installed, run
docker run -p 4444:4444 selenium/standalone-firefox:4.18.1
- If you do not have Docker, but you have Java
curl -L https://github.com/SeleniumHQ/selenium/releases/download/selenium-4.18.0/selenium-server-4.18.1.jar > selenium-server-4.18.1.jar java -jar selenium-server-4.18.1.jar standalone
- Start WebServer by running
./vendor/bin/mink-test-server
- Start PhpUnit
./vendor/bin/phpunit -v --coverage-clover=coverage.clover