# Installation

## Requirements

* PHP 7.4+
* Composer 2.0+

## Install WP\_Mock

Add WP\_Mock as a dev-dependency using Composer:

```shell
composer require --dev 10up/wp_mock
```

## Dependencies

WP\_Mock needs the following dependencies to work:

* PHPUnit ^9.5 (BSD 3-Clause license)
* Mockery ^1.6 (BSD 3-Clause license)
* Patchwork ^2.1 (MIT license)

They will be installed for you by Composer.

Next, you will need to configure PHPUnit first before enabling WP\_Mock. [Consult PHPUnit documentation](https://phpunit.de/documentation.html) for this step.

You will also need to [configure WP\_Mock with a bootstrap file](https://wp-mock.gitbook.io/documentation/getting-started/configuration) to use it in your tests.
