Last active
December 17, 2022 19:52
-
-
Save dgafka/744f9c41926b9f0b377be2b8c2c7eec7 to your computer and use it in GitHub Desktop.
testing-message-driven-architecture-in-php-05.php
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
$ecotoneTestSupport = EcotoneLite::bootstrapForTesting( | |
[OrderService::class, OrderNotifier::class, ChannelConfiguration::class], | |
$dependencyContainer, // our dependency container | |
); | |
$ecotoneTestSupport->getCommandBus()->send(PlaceOrder::create($orderId)); | |
$ecotoneTestSupport->run("notifications", PollingMetadata::create("notifications")->withTestingSetup(1, 5000, true)); | |
Assert::assertEquals(1, $ecotoneTestSupport->sendQueryWithRouting("notificationService.getSentNotificationsCount")); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment