Dieser Inhalt ist auch auf Deutsch verfügbar.
How can I run the unit tests for your Magento Extension?

The unit tests of our Magento 1 extensions are based on the EcomDev_PHPUnit
module that can be found on Github.
I recommend installing the extension via composer
like this:
composer config repositories.ecomdev-phpunit vcs git@github.com:vianetz/ecomdev-phpunit-magento1.git
composer require --dev ecomdev/ecomdev_phpunit dev-master
For detailed installation instructions please see the appropriate manual.
After installation of the EcomDev_PHPUnit
extension you can run e.g. the Advanced Invoice Layout extension tests by the following command in the root folder of your Magento installation:
phpunit --group Vianetz_AdvancedInvoiceLayout
If everything is fine you should get a green output that says that all tests ran successfully:
PHPUnit 9.5.28 by Sebastian Bergmann and contributors.
.............................. 30 / 30 (100%)
Time: 00:19.833, Memory: 48.50 MB
OK (30 tests, 34 assertions)
« Back to the FAQ overview