I have a issue while running the PHP UnitTest cases. I have updated my php version from 7 to 8 and also updated my phpunit version from 6.5 to 9.6 version, which will support PHP8. & also updated dbunit version from 3.0.0 to 4.0.0 After which, I am unable to read the DBUnit files, I am getting the below issue.
PHP Fatal error: Uncaught Error: Class "PHPUnit\DbUnit\TestCase" not found in /var/www/MyProject/lib/accounts/test/ModelTestCase.php:18
The code, where I am getting the issue, I have attached a screenshot of it.enter image description here
The project location & path is in same location as mentioned and working in php7. After upgrading to php8, its not able to read the file. Please can anyone able to tell, what might be the issue.
I am using the below dbunit library & its seems to be abandoned. https://packagist.org/packages/phpunit/dbunit
I tried to add the path manually. namespace accounts\test;
use PHPUnit\DbUnit\TestCase; require_once LITHIUM_APP_PATH . '/config/bootstrap/cache.php';
class ModelTestCase extends \PHPUnit\DbUnit\TestCase { }