Browse Source

fix #20; WebElement::hover calls Driver::move_to

Robert Utter 12 năm trước cách đây
mục cha
commit
056d374ff8
1 tập tin đã thay đổi với 1 bổ sung2 xóa
  1. 1 2
      lib/Selenium/Remote/WebElement.pm

+ 1 - 2
lib/Selenium/Remote/WebElement.pm

@@ -443,8 +443,7 @@ sub get_css_attribute {
 
 sub hover {
     my ($self) = @_;
-    my $res = { 'command' => 'hoverOverElement', 'id' => $self->{id} };
-    return $self->_execute_command($res);
+    return $self->{driver}->move_to( element => $self );
 }
 
 =head2 describe