language: ruby
rvm:
  - 2.3
  - 2.4
  - 2.5
  - jruby-9.1.16.0

bundler_args: --jobs 3 --retry 3

gemfile:
  - test/gemfiles/Gemfile-Rails-4-2
  - test/gemfiles/Gemfile-Rails-5-0
  - test/gemfiles/Gemfile-Rails-5-1
  - Gemfile

script:
  - rm "${BUNDLE_GEMFILE}.lock" && bundle exec rake

matrix:
  fast_finish: true

  allow_failures:
    - rvm: jruby-9.1.16.0

language: ruby
rvm:
  - 2.3
  - 2.4
  - 2.5
  - jruby-9.1.16.0

bundler_args: --jobs 3 --retry 3

gemfile:
  - test/gemfiles/Gemfile-Rails-4-2
  - test/gemfiles/Gemfile-Rails-5-0
  - test/gemfiles/Gemfile-Rails-5-1
  - Gemfile

before_install:
  - rm "${BUNDLE_GEMFILE}.lock"

matrix:
  fast_finish: true

  allow_failures:
    - rvm: jruby-9.1.16.0

Move lock file removal to before_install
Move lock file removal to before_install

So that it's run before bundle install. We can also remove back the
default `script:` as it was before.
