Miroslav Novak Posted June 3, 2018 Share Posted June 3, 2018 Hi, I'd like to automatically test our PrestaShop payment modules. I'd like to reuse some PrestaShop tests for that. But when I tried to run the PrestaShop 1.7.3.3 tests with "composer test" it failed with: Script PrestaShopBundle\Tests\Utils\Database::createTestDB handling the test event terminated with an exception Invalid argument supplied for foreach() How can I run the tests? Thanks in advance. Miroslav. My steps to reproduce the problem: git clone https://github.com/PrestaShop/PrestaShop cd PrestaShop git checkout 1.7.3.3 composer install php install-dev/index_cli.php --domain=localhost:7080 --base_uri=/vzoroveInstalaceLinux/rep/PrestaShop --db_server=127.0.0.1:13306 --db_name=PrestaShopRep --db_create=1 --name=PrestaShopRep -- PrestaShop works well on my localhost http://localhost:7080/vzoroveInstalaceLinux/rep/PrestaShop composer test -v Script PrestaShopBundle\Tests\Utils\Database::createTestDB handling the test event terminated with an exception [ErrorException] Invalid argument supplied for foreach() Exception trace: () at /mnt/c/tccont/mir/online-platba/vzoroveInstalaceLinux/presta/PrestaShop1.7.3.3/classes/Language.php:883 Composer\Util\ErrorHandler::handle() at /mnt/c/tccont/mir/online-platba/vzoroveInstalaceLinux/presta/PrestaShop1.7.3.3/classes/Language.php:883 LanguageCore::loadLanguages() at /mnt/c/tccont/mir/online-platba/vzoroveInstalaceLinux/presta/PrestaShop1.7.3.3/classes/Language.php:653 LanguageCore::getLanguage() at /mnt/c/tccont/mir/online-platba/vzoroveInstalaceLinux/presta/PrestaShop1.7.3.3/classes/Cookie.php:324 CookieCore->update() at /mnt/c/tccont/mir/online-platba/vzoroveInstalaceLinux/presta/PrestaShop1.7.3.3/classes/Cookie.php:91 CookieCore->__construct() at /mnt/c/tccont/mir/online-platba/vzoroveInstalaceLinux/presta/PrestaShop1.7.3.3/src/PrestaShopBundle/Install/Install.php:398 PrestaShopBundle\Install\Install->initializeTestContext() at /mnt/c/tccont/mir/online-platba/vzoroveInstalaceLinux/presta/PrestaShop1.7.3.3/src/PrestaShopBundle/Tests/Utils/Database.php:50 PrestaShopBundle\Tests\Utils\Database::createTestDB() at /usr/share/php/Composer/EventDispatcher/EventDispatcher.php:238 Composer\EventDispatcher\EventDispatcher->executeEventPhpScript() at /usr/share/php/Composer/EventDispatcher/EventDispatcher.php:192 Composer\EventDispatcher\EventDispatcher->doDispatch() at /usr/share/php/Composer/EventDispatcher/EventDispatcher.php:94 Composer\EventDispatcher\EventDispatcher->dispatchScript() at /usr/share/php/Composer/Command/ScriptAliasCommand.php:59 Composer\Command\ScriptAliasCommand->execute() at /usr/share/php/Symfony/Component/Console/Command/Command.php:256 Symfony\Component\Console\Command\Command->run() at /usr/share/php/Symfony/Component/Console/Application.php:841 Symfony\Component\Console\Application->doRunCommand() at /usr/share/php/Symfony/Component/Console/Application.php:189 Symfony\Component\Console\Application->doRun() at /usr/share/php/Composer/Console/Application.php:166 Composer\Console\Application->doRun() at /usr/share/php/Symfony/Component/Console/Application.php:120 Symfony\Component\Console\Application->run() at /usr/share/php/Composer/Console/Application.php:99 Composer\Console\Application->run() at /usr/bin/composer:44 Link to comment Share on other sites More sharing options...
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now