From c0b5ed8160bc7b31d016cdbb7971aa76410f5f20 Mon Sep 17 00:00:00 2001 From: Alexander Miertsch Date: Mon, 31 Aug 2015 20:35:14 +0200 Subject: [PATCH] Align test to reflect testing purpose --- tests/TransactionManagerTest.php | 5 +---- 1 file changed, 1 insertion(+), 4 deletions(-) diff --git a/tests/TransactionManagerTest.php b/tests/TransactionManagerTest.php index 5b09124..f075a78 100644 --- a/tests/TransactionManagerTest.php +++ b/tests/TransactionManagerTest.php @@ -268,8 +268,6 @@ public function it_returns_early_if_command_was_null_when_handling_events() //Step 1: Create null command $command = null; - $causationId = Uuid::uuid4(); - $initializeActionEvent = $this->prophesize(ActionEvent::class); $initializeActionEvent->getParam(CommandBus::EVENT_PARAM_MESSAGE)->willReturn($command); @@ -283,9 +281,8 @@ public function it_returns_early_if_command_was_null_when_handling_events() $transactionManager->onInitialize($initializeActionEvent->reveal()); $recordedEvent = $this->prophesize(Message::class); - $recordedEventCopy1 = $this->prophesize(Message::class); - $recordedEvent->withAddedMetadata('causation_id', $causationId->toString())->willReturn($recordedEventCopy1->reveal()); + $recordedEvent->withAddedMetadata('causation_id', Argument::any())->shouldNotBeCalled(); $stream = new Stream(new StreamName('event_stream'), [$recordedEvent->reveal()]);