Now the phpunit cannot be installed via pear, but we can with composer global
Run this to install phpunit: composer global require "phpunit/phpunit=5.5.*"
Reference link: https://phpunit.de/manual/current/en/installation.html#installation.composer
Then to run the phpunit in Lumen project, just go to the root application folder and run this command:
./vendor/bin/phpunit