Docker based testing environment for WordPress
A Docker based testing environment for WordPress.
curl -L https://raw.githubusercontent.com/miya0001/wpenv/master/run.sh | bash -s <tag> [wp_version] [container-name]
See:
Create a plugin and change directory into the plugin.
$ wp scaffold plugin my-plugin
$ cd wp-content/plugins/my-plugin
Run a docker in the directory and exec into the container.
$ curl -L https://raw.githubusercontent.com/miya0001/wpenv/master/run.sh | bash -s 7.1 4.8
$ docker exec -it wpenv bash
Run phpunit
.
$ phpunit
Change directory into the package commmand directory.
$ cd path/to/core-command
Run a docker in the directory and exec into the container.
$ curl -L https://raw.githubusercontent.com/miya0001/wpenv/master/run.sh | bash -s 7.1
$ docker exec -it wpenv bash
Install composer dependencies and run tests.
$ composer install
$ vendor/bin/behat
Tag | PHP Version | PHPUnit Version |
---|---|---|
5.2 | 5.2.17 | 3.6 |
5.3 | 5.3.29 | 4.8.36 |
5.4 | 5.4.31 | 4.8.36 |
5.5 | 5.5.38 | 4.8.36 |
5.6 | 5.6.31 | 5.7.21 |
7.0 | 7.0.23 | 6.3.0 |
7.1 | 7.1.9 | 6.3.0 |
7.2 | 7.2.0RC1 | 6.3.0 |