예제 #1
0
 public function execute($command_name, array $parameters = array())
 {
     $extra = ['type' => 'webdriver-activity', 'activity' => 'action', 'command' => $command_name];
     if (isset($parameters[':id'])) {
         $extra['id'] = $parameters[':id'];
     }
     $this->logger->debug(sprintf('Executing: ' . $command_name), $extra);
     return parent::execute($command_name, $parameters);
     // TODO: Change the autogenerated stub
 }
예제 #2
0
 /**
  * Test if two element IDs refer to the same DOM element.
  *
  * @param WebDriverElement $other
  * @return bool
  */
 public function equals(WebDriverElement $other)
 {
     return $this->executor->execute(DriverCommand::ELEMENT_EQUALS, array(':id' => $this->id, ':other' => $other->getID()));
 }
예제 #3
0
 /**
  * Release a modifier key
  *
  * @see WebDriverKeys
  * @param string $key
  * @return $this
  */
 public function releaseKey($key)
 {
     $this->executor->execute(DriverCommand::SEND_KEYS_TO_ACTIVE_ELEMENT, array('value' => array((string) $key)));
     return $this;
 }
예제 #4
0
 /**
  * @param int $x
  * @param int $y
  *
  * @return RemoteTouchScreen The instance.
  */
 public function up($x, $y)
 {
     $this->executor->execute(DriverCommand::TOUCH_UP, array('x' => $x, 'y' => $y));
     return $this;
 }
예제 #5
0
 /**
  * @param WebDriverCoordinates $where
  *
  * @return RemoteMouse
  */
 public function mouseUp(WebDriverCoordinates $where = null)
 {
     $this->moveIfNeeded($where);
     $this->executor->execute(DriverCommand::MOUSE_UP);
     return $this;
 }