/** * @expectedException \RayRutjes\DomainFoundation\Repository\ConcurrencyException */ public function testDetectsConcurrencyAndThrowsTheAccordingException() { $aggregateRootIdentifier = new AggregateRootIdentifierStub(Uuid::NIL); $aggregateRootType = Contract::createFromClassName('Product'); $messageIdentifier = new MessageIdentifier(UUID::NIL); $payload = new PayloadStub(); $event = new GenericEvent($aggregateRootIdentifier, 1, $messageIdentifier, $payload); $eventStream = new GenericEventStream([$event]); $this->eventStore->append($aggregateRootType, $eventStream); }
private function createTables() { $eventStore = new PdoEventStore(self::$pdo); $eventStore->createTable(); }
public function testCanCreateTheEventStoreTable() { $this->statement->expects($this->once())->method('execute'); $this->eventStore->createTable(); }
/** * Create the event store table. */ public function install() { $eventStore = new PdoEventStore($this->pdo); $eventStore->createTable(); }