/**
* Test fixer.
*
* @dataProvider dataFix
*/
public function testFix($data, $withHeader, $strict)
{
$fixedDataExpected = '<?php' . ($withHeader ? '
/**
* Header
*/' : '') . '
' . (is_bool($strict) ? 'declare(strict_types=' . ($strict ? '1' : '0') . ');
' : '') . "namespace 'namespace';";
$strictFixer = new StrictFixer($strict);
$fixedData = $strictFixer->fix($data);
$this->assertEquals($fixedDataExpected, $fixedData);
}