public function testFindingClassesWithCallableExcludes()
{
$result = Libraries::find('lithium', array('recursive' => true, 'path' => '/tests/cases', 'format' => function ($file, $config) {
return new SplFileInfo($file);
}, 'filter' => null, 'exclude' => function ($file) {
if ($file->getFilename() === 'LibrariesTest.php') {
return true;
}
}));
$this->assertCount(1, $result);
$this->assertIdentical(__FILE__, $result[0]->getRealPath());
}