private function getCoverageObject(\SplFileObject $coverageFile) { if ('<?php' === $coverageFile->fread(5)) { return include $coverageFile->getRealPath(); } $coverageFile->fseek(0); // the PHPUnit 3.x and below return unserialize($coverageFile->fread($coverageFile->getSize())); }