Skip to content

Commit bf535b9

Browse files
committed
Use StreamStore and message loader, fix cs
1 parent 2153d2d commit bf535b9

3 files changed

Lines changed: 4 additions & 4 deletions

File tree

tests/Benchmark/CommandToQueryBench.php

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -19,6 +19,7 @@
1919
use Patchlevel\EventSourcing\Snapshot\DefaultSnapshotStore;
2020
use Patchlevel\EventSourcing\Store\StreamDoctrineDbalStore;
2121
use Patchlevel\EventSourcing\Subscription\Engine\DefaultSubscriptionEngine;
22+
use Patchlevel\EventSourcing\Subscription\Engine\StoreMessageLoader;
2223
use Patchlevel\EventSourcing\Subscription\Repository\RunSubscriptionEngineRepositoryManager;
2324
use Patchlevel\EventSourcing\Subscription\Store\InMemorySubscriptionStore;
2425
use Patchlevel\EventSourcing\Subscription\Subscriber\MetadataSubscriberAccessorRepository;
@@ -64,7 +65,7 @@ public function setUp(): void
6465
$profileProjection = new ProfileProjector($projectionConnection);
6566

6667
$engine = new DefaultSubscriptionEngine(
67-
$store,
68+
new StoreMessageLoader($store),
6869
new InMemorySubscriptionStore(),
6970
new MetadataSubscriberAccessorRepository([
7071
$profileProjection,

tests/Integration/BasicImplementation/BasicIntegrationTest.php

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -329,7 +329,7 @@ public function testCommandBus(): void
329329

330330
public function testQueryBus(): void
331331
{
332-
$store = new DoctrineDbalStore(
332+
$store = new StreamDoctrineDbalStore(
333333
$this->connection,
334334
DefaultEventSerializer::createFromPaths([__DIR__ . '/Events']),
335335
DefaultHeadersSerializer::createFromPaths([
@@ -350,7 +350,7 @@ public function testQueryBus(): void
350350
$profileProjection = new ProfileProjector($this->connection);
351351

352352
$engine = new DefaultSubscriptionEngine(
353-
$store,
353+
new StoreMessageLoader($store),
354354
new InMemorySubscriptionStore(),
355355
new MetadataSubscriberAccessorRepository([
356356
$profileProjection,

tests/Integration/BasicImplementation/Projection/ProfileProjector.php

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,6 @@
1313
use Patchlevel\EventSourcing\Attribute\Teardown;
1414
use Patchlevel\EventSourcing\Tests\Integration\BasicImplementation\Events\NameChanged;
1515
use Patchlevel\EventSourcing\Tests\Integration\BasicImplementation\Events\ProfileCreated;
16-
use Patchlevel\EventSourcing\Tests\Integration\BasicImplementation\ProfileId;
1716
use Patchlevel\EventSourcing\Tests\Integration\BasicImplementation\Query\QueryProfileName;
1817

1918
#[Projector('profile-1')]

0 commit comments

Comments
 (0)