Selaa lähdekoodia

Configure wd context prefix for old FF

Daniel Gempesaw 9 vuotta sitten
vanhempi
sitoutus
bcaa00ade3
1 muutettua tiedostoa jossa 12 lisäystä ja 2 poistoa
  1. 12 2
      lib/Selenium/Firefox.pm

+ 12 - 2
lib/Selenium/Firefox.pm

@@ -121,7 +121,17 @@ has '_binary_args' => (
 
 has '+wd_context_prefix' => (
     is => 'ro',
-    default => sub { '' }
+    default => sub {
+        my ($self) = @_;
+
+        if ($self->marionette_enabled) {
+            return '';
+        }
+        else {
+            return '/hub';
+        }
+
+    }
 );
 
 =attr marionette_binary_port
@@ -186,7 +196,7 @@ has 'firefox_binary' => (
     is => 'lazy',
     coerce => \&coerce_firefox_binary,
     predicate => 1,
-    default => sub { '' }
+    default => sub { 'firefox' }
 );