Behat\Gherkin\Gherkin::addLoader PHP Метод

addLoader() публичный Метод

Adds loader to manager.
public addLoader ( Behat\Gherkin\Loader\LoaderInterface $loader )
$loader Behat\Gherkin\Loader\LoaderInterface Feature loader
    public function addLoader(LoaderInterface $loader)
    {
        $this->loaders[] = $loader;
    }

Usage Example

Пример #1
0
 public function testSetBasePath()
 {
     $gherkin = new Gherkin();
     $gherkin->addLoader($loader1 = $this->getLoaderMock());
     $gherkin->addLoader($loader2 = $this->getLoaderMock());
     $loader1->expects($this->once())->method('setBasePath')->with($basePath = '/base/path')->will($this->returnValue(null));
     $loader2->expects($this->once())->method('setBasePath')->with($basePath = '/base/path')->will($this->returnValue(null));
     $gherkin->setBasePath($basePath);
 }
All Usage Examples Of Behat\Gherkin\Gherkin::addLoader