1

When I try to debug magento2 by phpstorm and xdebug I got this error:

/opt/lampp/bin/php -dxdebug.remote_enable=1 -dxdebug.remote_mode=req -dxdebug.remote_port=9000 -dxdebug.remote_host=127.0.0.1 /tmp/ide-phpunit.php --no-configuration /opt/lampp/htdocs/magento_sample Testing started at 17:45 ... -#!/opt/lampp/bin/php

PHP Fatal error: Class 'Magento\TestFramework\TestCase\WebapiAbstract' not found in /opt/lampp/htdocs/magento_sample/dev/tests/api-functional/testsuite/Magento/Bundle/Api/CartItemRepositoryTest.php on line 10

PHP Stack trace:

PHP   1. {main}() /tmp/ide-phpunit.php:0

Fatal error: Class 'Magento\TestFramework\TestCase\WebapiAbstract' not found in /opt/lampp/htdocs/magento_sample/dev/tests/api-functional/testsuite/Magento/Bundle/Api/CartItemRepositoryTest.php on line 10

PHP 2. IDE_PHPUnit_Loader::init() /tmp/ide-phpunit.php:250 Call Stack:

2.1859 457720 1. {main}() /tmp/ide-phpunit.php:0PHP 3. IDE_PHPUnit_Loader::loadByAutoloader($path = uninitialized) /tmp/ide-phpunit.php:173

PHP 4. require_once() /tmp/ide-phpunit.php:246

2.3308 457720 2. IDE_PHPUnit_Loader::init() /tmp/ide-phpunit.php:250

PHP 5. PHPUnit_TextUI_Command::main($exit = uninitialized) /opt/lampp/bin/phpunit:46

2.3308 457720 3. IDE_PHPUnit_Loader::loadByAutoloader(???) /tmp/ide-phpunit.php:173

2.3311     460480   4. require_once('/opt/lampp/bin/phpunit') /tmp/ide-phpunit.php:246

PHP 6. PHPUnit_TextUI_Command->run($argv = uninitialized, $exit = uninitialized) /opt/lampp/lib/php/PHPUnit/TextUI/Command.php:126

2.3349     690272   5. PHPUnit_TextUI_Command::main(???) /opt/lampp/bin/phpunit:46

PHP 7. PHPUnit_Runner_BaseTestRunner->getTest($suiteClassName = uninitialized, $suiteClassFile = uninitialized) /opt/lampp/lib/php/PHPUnit/TextUI/Command.php:145

2.3349 690368 6. PHPUnit_TextUI_Command->run(???, ???) /opt/lampp/lib/php/PHPUnit/TextUI/Command.php:126

PHP 8. PHPUnit_Framework_TestSuite->addTestFiles($filenames = uninitialized) /opt/lampp/lib/php/PHPUnit/Runner/BaseTestRunner.php:96

2.3385 852992 7. PHPUnit_Runner_BaseTestRunner->getTest(???, ???) /opt/lampp/lib/php/PHPUnit/TextUI/Command.php:145

PHP 9. PHPUnit_Framework_TestSuite->addTestFile($filename = uninitialized, $phptOptions = uninitialized) /opt/lampp/lib/php/PHPUnit/Framework/TestSuite.php:419

23.8450 2452624 8. PHPUnit_Framework_TestSuite->addTestFiles(???) /opt/lampp/lib/php/PHPUnit/Runner/BaseTestRunner.php:96

PHP 10. PHPUnit_Util_Fileloader::checkAndLoad($filename = uninitialized) /opt/lampp/lib/php/PHPUnit/Framework/TestSuite.php:358

23.8450 2452624 9. PHPUnit_Framework_TestSuite->addTestFile(???, ???) /opt/lampp/lib/php/PHPUnit/Framework/TestSuite.php:419

PHP 11. PHPUnit_Util_Fileloader::load($filename = uninitialized) /opt/lampp/lib/php/PHPUnit/Util/Fileloader.php:79

PHP 12. include_once() /opt/lampp/lib/php/PHPUnit/Util/Fileloader.php:95

23.8648 2508240 10. PHPUnit_Util_Fileloader::checkAndLoad(???) /opt/lampp/lib/php/PHPUnit/Framework/TestSuite.php:358

23.8648 2508400 11. PHPUnit_Util_Fileloader::load(???) /opt/lampp/lib/php/PHPUnit/Util/Fileloader.php:79

23.8732 2551800 12. include_once('/opt/lampp/htdocs/magento_sample/dev/tests/api-functional/testsuite/Magento/Bundle/Api/CartItemRepositoryTest.php') /opt/lampp/lib/php/PHPUnit/Util/Fileloader.php:95

Process finished with exit code 255

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Browse other questions tagged or ask your own question.