public function tearDown() { parent::tearDown(); $this->em->clear(); $this->em->close(); foreach ($this->dataFiles() as $src => $dst) { $path = self::DSTDIR . '/' . $dst; if (file_exists($path)) { if (is_dir($path)) { $this->delTree($path); } else { unlink($path); } } } }