You are here

protected function XAutoloadUnitTestCase::_findClass in X Autoload 7.2

3 calls to XAutoloadUnitTestCase::_findClass()
XAutoloadUnitTestCase::testLibPSR0 in ./xautoload.test
XAutoloadUnitTestCase::testNsReg in ./xautoload.test
XAutoloadUnitTestCase::testNsRegNested in ./xautoload.test

File

./xautoload.test, line 101

Class

XAutoloadUnitTestCase

Code

protected function _findClass($finder, $class, array $expectedSuggestions) {
  try {
    if (TRUE) {
      for ($iAccept = 0; $iAccept < count($expectedSuggestions); ++$iAccept) {
        $api = new xautoload_Mock_InjectedAPI_findFile($this, $class, $expectedSuggestions, $iAccept);
        $finder
          ->findFile($api, $class);
        $api
          ->finish();
      }
    }
    $api = new xautoload_Mock_InjectedAPI_findFile($this, $class, $expectedSuggestions);
    $finder
      ->findFile($api, $class);
    $api
      ->finish();
  } catch (Exception $e) {
    $this
      ->assert(FALSE, 'Exception: ' . $e
      ->getMessage());
    return;
  }
  $this
    ->assert(TRUE, "Successfully loaded {$class}");
}