Changed injection method from class to interface

This commit is contained in:
Kevin Frantz 2019-02-15 22:55:11 +01:00
parent c0113ecd32
commit 06053c6bcf
2 changed files with 4 additions and 6 deletions

View File

@ -5,7 +5,6 @@
# https://symfony.com/doc/current/best_practices/configuration.html#application-related-configuration
parameters:
locale: 'en'
services:
# default configuration for services in *this* file
_defaults:
@ -44,7 +43,7 @@ services:
# add more service definitions when explicit configuration is needed
# please note that last definitions always *replace* previous ones
# testing configuration
# Needed for integration tests
App\Domain\RequestManagement\Entity\RequestedEntityService:
public: true
public: true

View File

@ -4,7 +4,6 @@ namespace tests\Integration\Domain\RequestManagement\Entity;
use Symfony\Bundle\FrameworkBundle\Test\KernelTestCase;
use App\Domain\RequestManagement\Entity\RequestedEntityServiceInterface;
use App\Domain\RequestManagement\Entity\RequestedEntityService;
use App\Entity\Source\AbstractSource;
/**
@ -25,7 +24,7 @@ class RequestedEntityServiceIntegrationTest extends KernelTestCase
public function setUp(): void
{
self::bootKernel();
$this->requestedEntityService = self::$container->get(RequestedEntityService::class);
$this->requestedEntityService = self::$container->get(RequestedEntityServiceInterface::class);
}
public function testClassAccessors(): void