Dumplie\CustomerService\Tests\Doctrine\ORMCustomerServiceContext::__construct PHP Method

__construct() public method

public __construct ( EntityManager $entityManager, Dumplie\SharedKernel\Application\EventLog $eventLog, Dumplie\SharedKernel\Tests\Context\CommandBusFactory $commandBusFactory )
$entityManager Doctrine\ORM\EntityManager
$eventLog Dumplie\SharedKernel\Application\EventLog
$commandBusFactory Dumplie\SharedKernel\Tests\Context\CommandBusFactory
    public function __construct(EntityManager $entityManager, EventLog $eventLog, CommandBusFactory $commandBusFactory)
    {
        $this->orders = new ORMOrders($entityManager);
        $this->payments = new ORMPayments($entityManager);
        $this->transactionFactory = new ORMFactory($entityManager);
        $this->commandBus = $this->createCommandBus($commandBusFactory, [new TransactionExtension($this->transactionFactory)]);
        $this->eventLog = $eventLog;
        $this->eventLog->subscribeFor(CustomerPlacedOrder::class, new NewOrderListener($this->orders));
    }
ORMCustomerServiceContext