Be sure you have php and mysql installed on your mac/PC
After scaffolding with wp-cli
, run
bash bin/install-wp-tests.sh wordpress_test root '' 127.0.0.1 latest
If the database is installed, you can delete it before running this command.
After that phpunit
should be working.
The test wp is installed in a temporary folder that looks something like (on mac)
/var/folders/xj/14b3w8w51ll6rw09q72p45cr0000gn/T/wordpress/