Example #1
0
 public function configureServices()
 {
     $servicesFile = $this->getAppConfig()['core']['configDir'] . $this->getAppConfig()['core']['servicesFile'];
     $serviceParser = new ServiceParser($servicesFile);
     $serviceParser->loadServices()->loadControllers($this->getControllers())->parse();
     // Sets up the Validator service provider
     $this->register(new ValidatorServiceProvider());
     return $this;
 }
Example #2
0
 /**
  * @expectedException ErrorException
  */
 public function testEmptyServiceParseCallThrowsException()
 {
     \Flint\App::getInstance(['options' => ['debug' => true], 'core' => ['configDir' => __DIR__ . '/../data']]);
     $parser = new ServiceParser('fakefile.php');
     $parser->parse();
 }