Forráskód Böngészése

Pass headless opts directly in at/firefox.test for #375 repro

George S. Baugh 7 éve
szülő
commit
3c9ed8c87a
1 módosított fájl, 7 hozzáadás és 2 törlés
  1. 7 2
      at/firefox.test

+ 7 - 2
at/firefox.test

@@ -5,7 +5,12 @@ use Selenium::Firefox;
 use Test::More tests => 2;
 use Test::Fatal;
 
-$ENV{MOZ_HEADLESS} = 1;
 my $driver;
-is( exception { $driver = Selenium::Firefox->new(); }, undef, "can spawn new Selenium::Firefox");
+is( exception { $driver = Selenium::Firefox->new(
+	extra_capabilities => {
+        'moz:firefoxOptions' => {
+            args    => [ '-headless' ],
+        },
+    },
+); }, undef, "can spawn new Selenium::Firefox");
 is( exception { $driver->shutdown_binary; }, undef, "can shutdown binary correctly");