PHPackages                             peridot-php/webdriver-manager - PHPackages - PHPackages  [Skip to content](#main-content)[PHPackages](/)[Directory](/)[Categories](/categories)[Trending](/trending)[Leaderboard](/leaderboard)[Changelog](/changelog)[Analyze](/analyze)[Collections](/collections)[Log in](/login)[Sign up](/register)

1. [Directory](/)
2. /
3. [Testing &amp; Quality](/categories/testing)
4. /
5. peridot-php/webdriver-manager

ActiveLibrary[Testing &amp; Quality](/categories/testing)

peridot-php/webdriver-manager
=============================

Library and command line tool for managing Selenium WebDriver

1.3.1(9y ago)3535.5k—1.8%7[3 issues](https://github.com/peridot-php/webdriver-manager/issues)1MITPHPPHP &gt;=5.4.0

Since Mar 17Pushed 7y ago3 watchersCompare

[ Source](https://github.com/peridot-php/webdriver-manager)[ Packagist](https://packagist.org/packages/peridot-php/webdriver-manager)[ RSS](/packages/peridot-php-webdriver-manager/feed)WikiDiscussions master Synced 2d ago

READMEChangelog (1)Dependencies (5)Versions (7)Used By (1)

WebDriver Manager
=================

[](#webdriver-manager)

[![Build Status](https://camo.githubusercontent.com/ca7b0a4acae4f367552052748c9c4807bcb1aac70cb534817e5d5b86f8328a5f/68747470733a2f2f7472617669732d63692e6f72672f70657269646f742d7068702f7765626472697665722d6d616e616765722e706e67)](https://travis-ci.org/peridot-php/webdriver-manager)[![Scrutinizer Code Quality](https://camo.githubusercontent.com/8ff540c9ecd2d79a9f9435dfef49ae893084c0d64917fb8b12da92012e5f6e00/68747470733a2f2f7363727574696e697a65722d63692e636f6d2f672f70657269646f742d7068702f7765626472697665722d6d616e616765722f6261646765732f7175616c6974792d73636f72652e706e673f623d6d6173746572)](https://scrutinizer-ci.com/g/peridot-php/webdriver-manager/?branch=master)

The perfect companion for projects with functional tests. Heavily inspired by the `webdriver-manager` that ships with [protractor](https://github.com/angular/protractor). WebDriver Manager allows you to keep Selenium Server binaries up to date. It also provides a packaged solution for easily starting Selenium Server.

In addition to an easy to use command line application, WebDriver Manager provides a library for managing Selenium binaries in your own apps and tools.

Installation
------------

[](#installation)

WebDriver Manager is meant to be a drop in installation for any project using Selenium WebDriver for functional tests.

```
$ composer require --dev peridot-php/webdriver-manager

```

Once installed, you can operate Selenium Server from the comfort of your project:

```
$ vendor/bin/manager start

```

Usage
-----

[](#usage)

[![WebDriver Manager Usage](https://camo.githubusercontent.com/a7b0b2699ae916a704c3ad57b86e5be41be50e159960493ce1975028f2e58ff4/68747470733a2f2f7261772e6769746875622e636f6d2f70657269646f742d7068702f7765626472697665722d6d616e616765722f6d61737465722f696d672f75736167652e706e67 "WebDriver Manager Usage")](https://camo.githubusercontent.com/a7b0b2699ae916a704c3ad57b86e5be41be50e159960493ce1975028f2e58ff4/68747470733a2f2f7261772e6769746875622e636f6d2f70657269646f742d7068702f7765626472697665722d6d616e616765722f6d61737465722f696d672f75736167652e706e67)

### clean

[](#clean)

Remove all installed binaries.

[![WebDriver clean command](https://camo.githubusercontent.com/af26b7934d15b2d1b37c7cf139cbc64c73fd130c8967d9a494c05c703a1633b1/68747470733a2f2f7261772e6769746875622e636f6d2f70657269646f742d7068702f7765626472697665722d6d616e616765722f6d61737465722f696d672f636c65616e2e706e67 "WebDriver clean command")](https://camo.githubusercontent.com/af26b7934d15b2d1b37c7cf139cbc64c73fd130c8967d9a494c05c703a1633b1/68747470733a2f2f7261772e6769746875622e636f6d2f70657269646f742d7068702f7765626472697665722d6d616e616765722f6d61737465722f696d672f636c65616e2e706e67)

### status

[](#status)

List all available binaries and their installed status. Status shows if the binary is installed, out of date, or missing.

[![WebDriver status command](https://camo.githubusercontent.com/7d4862b2efdca91ddef60c8b21f2900ae796998a55b132ed4d3616feb8ae93ac/68747470733a2f2f7261772e6769746875622e636f6d2f70657269646f742d7068702f7765626472697665722d6d616e616765722f6d61737465722f696d672f7374617475732e706e67 "WebDriver status command")](https://camo.githubusercontent.com/7d4862b2efdca91ddef60c8b21f2900ae796998a55b132ed4d3616feb8ae93ac/68747470733a2f2f7261772e6769746875622e636f6d2f70657269646f742d7068702f7765626472697665722d6d616e616765722f6d61737465722f696d672f7374617475732e706e67)

### update

[](#update)

The update command downloads current binaries and deletes old ones.

[![WebDriver update command](https://camo.githubusercontent.com/520ec36849a83c53e1ea5a5084970fd221081925aebab987b42c0bc99bdb4e16/68747470733a2f2f7261772e6769746875622e636f6d2f70657269646f742d7068702f7765626472697665722d6d616e616765722f6d61737465722f696d672f7570646174652e706e67 "WebDriver update command")](https://camo.githubusercontent.com/520ec36849a83c53e1ea5a5084970fd221081925aebab987b42c0bc99bdb4e16/68747470733a2f2f7261772e6769746875622e636f6d2f70657269646f742d7068702f7765626472697665722d6d616e616765722f6d61737465722f696d672f7570646174652e706e67)

### start

[](#start)

Starts Selnium Server with all drivers managed by WebDriver Manager. The start command will run an update at start to make sure drivers are available and up to date.

[![WebDriver start command](https://camo.githubusercontent.com/5714832334caac447eb5e502b08091bea2545f94cb6b81d74f60aca7543e0577/68747470733a2f2f7261772e6769746875622e636f6d2f70657269646f742d7068702f7765626472697665722d6d616e616765722f6d61737465722f696d672f73746172742e706e67 "WebDriver start command")](https://camo.githubusercontent.com/5714832334caac447eb5e502b08091bea2545f94cb6b81d74f60aca7543e0577/68747470733a2f2f7261772e6769746875622e636f6d2f70657269646f742d7068702f7765626472697665722d6d616e616765722f6d61737465722f696d672f73746172742e706e67)

Library Usage
-------------

[](#library-usage)

WebDriver manager exposes a really simple interface that makes it easy to leverage in your own applications and tools:

```
use Peridot\WebDriverManager\Manager;

$manager = new Manager();

$manager->update(); //update all binaries
$manager->update('selenium'); //only update selenium

$manager->clean(); //remove installed binaries

$manager->startInForeground(); //start selenium in the foreground on port 4444
$manager->startInForeground(9999); //start selenium in the foreground on port 9999
$manager->startInBackground(); //start selenium in the background on port 4444
$manager->startInBackground(9999); //start in the background on port 9999

$path = $manager->getInstallPath(); //where binaries are installed
$manager->setInstallPath(__DIR__); //set the path to install binaries

$manager->addBinary(new MyCustomDriver()); //add a binary to manage
$manager->removeBinary('chromdedriver'); //remove a managed binary
$binaries = $manager->getBinaries(); //get a collection of managed binaries
```

### A note on starting Selenium in the background

[](#a-note-on-starting-selenium-in-the-background)

WebDriver Manager does not block when starting a background process. This makes it difficult to see if Selenium encountered any errors (perhaps a corrupt binary?). The `SeleniumProcess` class provides a method for checking the status of the process. If you want to check that Selenium Server started in the background ok, you might try something like this:

```
$process = $manager->startInBackground();
usleep(250000); //give Selenium a quarter of a second to validate input
if (! $process->isRunning()) {
	//Selenium encountered an error
	print $process->getError();
	$process->close();
    return;
}

//do rad Selenium things
```

For more information, see the [API docs](http://peridot-php.github.io/webdriver-manager/docs/);

Examples
--------

[](#examples)

The API has been used to create a [custom Behat listener](https://github.com/brianium/behavior-driven-todos/blob/master/src/Test/WebDriverListener.php) capable of starting the server before Mink tests are run. This tool is included as part of a demo project known as [behavior driven todos](https://github.com/brianium/behavior-driven-todos).

Running Tests
-------------

[](#running-tests)

WebDriver Manager's tests were written using the [Peridot](http://peridot-php.github.io/) test framework.

Unit tests can be run like so:

```
$ vendor/bin/peridot

```

And integration tests can be run like this:

```
$ vendor/bin/peridot --grep *.it.php

```

Contributing
------------

[](#contributing)

Please feel free to open issues or pull requests.

###  Health Score

38

—

LowBetter than 83% of packages

Maintenance18

Infrequent updates — may be unmaintained

Popularity38

Limited adoption so far

Community20

Small or concentrated contributor base

Maturity62

Established project with proven stability

 Bus Factor1

Top contributor holds 89.3% of commits — single point of failure

How is this calculated?**Maintenance (25%)** — Last commit recency, latest release date, and issue-to-star ratio. Uses a 2-year decay window.

**Popularity (30%)** — Total and monthly downloads, GitHub stars, and forks. Logarithmic scaling prevents top-heavy scores.

**Community (15%)** — Contributors, dependents, forks, watchers, and maintainers. Measures real ecosystem engagement.

**Maturity (30%)** — Project age, version count, PHP version support, and release stability.

###  Release Activity

Cadence

Every ~116 days

Recently: every ~145 days

Total

6

Last Release

3545d ago

### Community

Maintainers

![](https://www.gravatar.com/avatar/f71e23eec19a24f64f37c622e76e725c9a580f83ff40c411da9bad97e0a49089?d=identicon)[brianium](/maintainers/brianium)

---

Top Contributors

[![brianium](https://avatars.githubusercontent.com/u/636651?v=4)](https://github.com/brianium "brianium (109 commits)")[![marcandreuf](https://avatars.githubusercontent.com/u/167619?v=4)](https://github.com/marcandreuf "marcandreuf (6 commits)")[![ezzatron](https://avatars.githubusercontent.com/u/100152?v=4)](https://github.com/ezzatron "ezzatron (3 commits)")[![jails](https://avatars.githubusercontent.com/u/1306941?v=4)](https://github.com/jails "jails (2 commits)")[![austinsmorris](https://avatars.githubusercontent.com/u/1616868?v=4)](https://github.com/austinsmorris "austinsmorris (1 commits)")[![formigone](https://avatars.githubusercontent.com/u/852234?v=4)](https://github.com/formigone "formigone (1 commits)")

---

Tags

testingseleniumwebdriver

### Embed Badge

![Health badge](/badges/peridot-php-webdriver-manager/health.svg)

```
[![Health](https://phpackages.com/badges/peridot-php-webdriver-manager/health.svg)](https://phpackages.com/packages/peridot-php-webdriver-manager)
```

###  Alternatives

[behat/behat

Scenario-oriented BDD framework for PHP

4.0k101.8M2.2k](/packages/behat-behat)[brianium/paratest

Parallel testing for PHP

2.5k136.1M986](/packages/brianium-paratest)[symfony/panther

A browser testing and web scraping library for PHP and Symfony.

3.1k16.2M141](/packages/symfony-panther)[infection/infection

Infection is a Mutation Testing framework for PHP. The mutation adequacy score can be used to measure the effectiveness of a test set in terms of its ability to detect faults.

2.2k28.9M2.4k](/packages/infection-infection)[behat/mink-selenium2-driver

Selenium2 (WebDriver) driver for Mink framework

51960.3M723](/packages/behat-mink-selenium2-driver)[lmc/steward

Steward - makes Selenium WebDriver + PHPUnit testing easy and robust

222167.4k1](/packages/lmc-steward)

PHPackages © 2026

[Directory](/)[Categories](/categories)[Trending](/trending)[Changelog](/changelog)[Analyze](/analyze)
