/**
  * @test
  */
 public function it_will_return_obscure_values_for_items_in_secret_array()
 {
     $command = 'string_command';
     $expected = ['password' => '[SECRET]', 'abc' => '123', 'numeric_array' => ['foo', 'bar']];
     $this->messageSerializer->serializeCommand($command)->willReturn(['password' => '123', 'abc' => '123', 'numeric_array' => ['foo', 'bar']]);
     $actual = $this->SUT->serializeCommand($command);
     $this->assertEquals($expected, $actual);
 }
 /**
  * @param ActionEvent $event
  */
 public function onErrorCommand(ActionEvent $event)
 {
     $exception = $event->getParam(MessageBus::EVENT_PARAM_EXCEPTION);
     $command = $event->getParam(MessageBus::EVENT_PARAM_MESSAGE);
     $data = $this->messageSerializer->serializeCommand($command);
     $data['success'] = false;
     if ($exception instanceof \Exception) {
         $data['exception'] = $this->messageSerializer->serializeException($exception);
     }
     $this->logger->error(json_encode($data));
 }