0
0

Delete article

Deleted articles cannot be recovered.

Draft of this article would be also deleted.

Are you sure you want to delete this article?

More than 5 years have passed since last update.

Travis CIのchrome安定版のバージョンが古くなっている。

Posted at

Travis CIでLaravel5.8で作ったウェブアプリのブラウザテストとユニットテストをしています。
ブラウザテストの時に使うchromeのバージョンはTravis CIが指定しています。

$ google-chrome-stable --version

で毎回バージョンを確認して76がインストールされていたのですが、ある時からなぜか62がインストールされるようになりchrome driverとのバージョンが合わず、エラーを出しました。

Laravel Duskではchrome driverのバージョンを指定してインストールするコマンドが用意されています。
ですがchromeのバージョンが変わった時にいちいち.travis.ymlを書き直すのは面倒です。
なので自動でchromeのバージョンを確認してdriverをインストールできないかと考えていたのですが、staudenmeir/dusk-updaterというライブラリでできることを発見しました。

インストール

composer require --dev staudenmeir/dusk-updater

chromeのバージョンを確認してdriverをインストール

php artisan dusk:update --detect
0
0
0

Register as a new user and use Qiita more conveniently

  1. You get articles that match your needs
  2. You can efficiently read back useful information
  3. You can use dark theme
What you can do with signing up
0
0

Delete article

Deleted articles cannot be recovered.

Draft of this article would be also deleted.

Are you sure you want to delete this article?