File tree Expand file tree Collapse file tree 1 file changed +16
-6
lines changed Expand file tree Collapse file tree 1 file changed +16
-6
lines changed Original file line number Diff line number Diff line change 3232 */
3333abstract class Container extends AbstractWebDriver
3434{
35+ const LEGACY_ELEMENT_ID = 'ELEMENT ' ;
36+ const WEBDRIVER_ELEMENT_ID = 'element-6066-11e4-a52e-4f735466cecf ' ;
37+
3538 /**
3639 * {@inheritdoc}
3740 */
@@ -203,12 +206,19 @@ public function locate($using, $value)
203206 */
204207 protected function webDriverElement ($ value )
205208 {
206- return array_key_exists ('ELEMENT ' , (array ) $ value )
207- ? new Element (
208- $ this ->getElementPath ($ value ['ELEMENT ' ]), // url
209- $ value ['ELEMENT ' ] // id
210- )
211- : null ;
209+ if (array_key_exists (self ::LEGACY_ELEMENT_ID , (array ) $ value )) {
210+ return new Element (
211+ $ this ->getElementPath ($ value [self ::LEGACY_ELEMENT_ID ]), // url
212+ $ value [self ::LEGACY_ELEMENT_ID ] // id
213+ );
214+ }
215+
216+ if (array_key_exists (self ::WEBDRIVER_ELEMENT_ID , (array ) $ value )) {
217+ return new Element (
218+ $ this ->getElementPath ($ value [self ::WEBDRIVER_ELEMENT_ID ]), // url
219+ $ value [self ::WEBDRIVER_ELEMENT_ID ] // id
220+ );
221+ }
212222 }
213223
214224 /**
You can’t perform that action at this time.
0 commit comments