public function testProcessFileWithException()
{
$file = new SplFileInfo(__FILE__, '', basename(__FILE__));
$this->eventDispatcher->addListener(Events::DOCUMENT_HEADER, function () {
throw new \Exception('Exception message');
});
$document = $this->processor->processFile($file);
}