/**
  * @return Router
  */
 private function getRouter()
 {
     $configBuilder = new ConfigTreeBuilder();
     $configBuilder->addSettingsFromPaths([__DIR__ . '/fixtures/sample_routing_file.php']);
     $wholeConfig = $configBuilder->buildConfigTreeAndReset();
     $routingConfig = $wholeConfig->getSubtreeFromPath('rest-in-peace/routing');
     return new Router($routingConfig);
 }
Пример #2
0
 /**
  * @When I get a Config Tree object from the Config Tree Builder
  */
 public function iGetAConfigTreeObjectFromTheConfigTreeBuilder()
 {
     $this->configTree = $this->configTreeBuilder->buildConfigTreeAndReset();
 }