Selenium2 + phpunit -> drag and drop on xpath
问题 I use PHPUnit_Extensions_Selenium2TestCase Selenium and phpunit and I need make drag and drop one xpath element, on diferent emelent. Like on this screen, to change position on tree (category tree) 回答1: $srcDrag=$this->byId('draggable'); $targetDrop=$this->byId('droppable'); $stateChecker=$this->byCssSelector('#droppable > p'); $this->assertEquals("Drop here",$stateChecker->text()); $this->moveto($srcDrag); $this->buttondown(); $this->moveto($targetDrop); $this->buttonup(); 回答2: Drag and Drop