Exemple #1
0
 /**
  * Factory a featureElement
  * 
  * @return FeatureInterface
  */
 public function factory($filename)
 {
     if (!file_exists($filename)) {
         throw new NotBuildableException(sprintf('File "%s" not found', $filename));
     }
     $feature = $this->parser->parse(file_get_contents($filename), $filename);
     $proxy = new ModelGherkin($feature);
     $report = $this->reportRepository->getReportByFeature($proxy);
     return new ModelFeature($proxy, $report, $this->container);
 }