/**
  * @param $string
  * @param $excepted
  * @dataProvider dataProviderExtractClassName
  */
 public function testExtractClassName($string, $excepted)
 {
     $this->assertEquals($excepted, ClassHelper::extractClass($string));
 }
Example #2
-1
 /**
  * @return AbstractHtmlElement
  *
  * @throws NotExistsException
  */
 private function getSubmitElement()
 {
     $elementsIterator = $this->elements->getAll();
     foreach ($elementsIterator as $element) {
         if (ClassHelper::extractClass(get_class($element)) === 'SubmitElement') {
             return $element;
         }
     }
     throw new NotExistsException('The form "' . $this->attributes->get('id') . '" has no submit element.');
 }