浏览代码

travis run dusk

jqh 5 年之前
父节点
当前提交
323750ed70
共有 2 个文件被更改,包括 5 次插入6 次删除
  1. 1 1
      .travis.yml
  2. 4 5
      tests/ChromeProcess.php

+ 1 - 1
.travis.yml

@@ -44,7 +44,7 @@ install:
 before_script:
 #  - chmod 777 ./vendor/laravel/dusk/bin/chromedriver-linux
 #  - ./vendor/laravel/dusk/bin/chromedriver-linux --headless --disable-gpu --remote-debugging-port=9515 http://localhost &
-  - google-chrome-stable --headless --disable-gpu --remote-debugging-port=9222 http://localhost &
+  - google-chrome --headless --disable-gpu --remote-debugging-port=9222 http://localhost &
   - php artisan serve &
 
 script:

+ 4 - 5
tests/ChromeProcess.php

@@ -12,11 +12,10 @@ class ChromeProcess extends BaseChromeProcess
 
         if ($this->onWindows()) {
             $this->driver = realpath(__DIR__.'/resources/drivers/chromedriver-win.exe');
+        } elseif ($this->onMac()) {
+            $this->driver = realpath(__DIR__.'/resources/drivers/chromedriver-mac');
+        } else {
+            $this->driver = realpath(__DIR__.'/resources/drivers/chromedriver-linux');
         }
-        //elseif ($this->onMac()) {
-        //    $this->driver = realpath(__DIR__.'/resources/drivers/chromedriver-mac');
-        //} else {
-        //    $this->driver = realpath(__DIR__.'/resources/drivers/chromedriver-linux');
-        //}
     }
 }