So I have a simple unit test file like this:
class testService extends UnitTestCase {
function setUp() {
parent::setUp();
}
function testCall() {
$service = \Drupal::service('plugin.manager.rest');
}
...
}
vendor/bin/phpunit -c core/ modules/custom/module-name/
has the error of ReflectionException: Class does not exist
in Devel, I can execute PHP with this line:
$service = \Drupal::service('plugin.manager.rest');
What do I miss?
Thanks