title: Validate Command Monolog Output in Symfony 4 Unit Test
body: <p>In <a href="https://symfony.com/doc/current/console.html#testing-commands" rel="nofollow noreferrer">https://symfony.com/doc/current/console.html#testing-commands</a>
  Users can see how to test Commands using Unit Testing.</p>
  
  <p>The issue is that following this process, Console output made via Monolog can't be tested. </p>
  
  <pre><code>$output = $commandTester-&gt;getDisplay();
  # Returns ''
  </code></pre>
  
  <p>Therefore all asserts on the $output are false.</p>
  
  <p>Anybody has any idea on how to unit test Monolog Outputs in Symfony Commands in Symfony 4?</p>