Ejemplo n.º 1
0
 protected function assertRelations(Accessor\AbstractAccessor $accessor, $selectorStart)
 {
     $con = $accessor->getConnection();
     $accessor1 = new Accessor\ByClassNameAccessor('some_class1', 'p', array(), $con);
     $accessor2 = new Accessor\ByClassNameAccessor('some_class2', 'span', array(), $con);
     $accessor->near($accessor1)->under($accessor2);
     $this->assertEquals($selectorStart . '_sahi._near(_sahi._byClassName("some_class1", "p")), ' . '_sahi._under(_sahi._byClassName("some_class2", "span")))', $accessor->getAccessor());
 }
Ejemplo n.º 2
0
 /**
  * Drag'n'Drop current element onto another.
  *
  * @param   AbstractAccessor    $to destination element
  */
 public function dragDrop(AbstractAccessor $to)
 {
     $this->con->executeStep(sprintf('_sahi._dragDrop(%s, %s)', $this->getAccessor(), $to->getAccessor()));
 }