예제 #1
0
파일: Staging.php 프로젝트: rvanlaak/Twig
 public function addTest(Twig_Test $test)
 {
     $this->tests[$test->getName()] = $test;
 }
예제 #2
0
 /**
  * Registers a Test.
  *
  * @param Twig_Test $test A Twig_Test instance
  */
 public function addTest(Twig_Test $test)
 {
     if ($this->extensionInitialized) {
         throw new LogicException(sprintf('Unable to add test "%s" as extensions have already been initialized.', $test->getName()));
     }
     $this->staging->addTest($test);
 }