I am currently developing a Flow package and would like to test it using PHPUnit. I wrote some a basic test for one of my models in the Tests directory of my package.
The problem occurred when I tried to run PHPUnit with the test directory as argument, I got the following error:
Install the BuildEssentials from https://github.com/neos/BuildEssentials.
The package contains a UnitTests.xml config file which includes some config values and a bootstrap file.
Go into Build/PhpUnit and run phpunit -c UnitTests.xml for unit tests and phpunit -c FunctionalTests.xml for the functional tests. The config implements an “All Tests” test suit.
Check if you have written the test case correctly or not. To run PHP unit testing, you need to first set your directory structure after installing the tool. Check this guide on php unit testing on how you can organize the directory structure.