From 6c9636877c24aed5b40a80982165dd761170aa0a Mon Sep 17 00:00:00 2001 From: Jason Chen Date: Fri, 1 Nov 2019 16:52:29 -0400 Subject: [PATCH] Fix Travis tests failing on distributions other than trusty (#606) * Revert ".travis.yml: Set "dist" to "trusty" (#600)" This reverts commit ac8f6aba3e4fe2d5728c5809b2b61ed91c0b5432. Doing this to run tests on Travis to investigate why they aren't passing. * Explicitly require locations.rb in rspec.rb Tentative fix for tests not passing in xenial but passing in trusty. This might be because different distributions load files in a different order. In xenial, `rspec.rb` might get loaded before `locations.rb`, making `Locations` uninitialized. Explicit require fixes this. --- .travis.yml | 1 - spec/support/rspec.rb | 2 ++ 2 files changed, 2 insertions(+), 1 deletion(-) diff --git a/.travis.yml b/.travis.yml index 506966bc..a5a875fc 100644 --- a/.travis.yml +++ b/.travis.yml @@ -2,7 +2,6 @@ env: global: - CC_TEST_REPORTER_ID=c18df080592f9c99ca8080a6d5e052aa5fd3964044a0fe0b71e48f8e18998dc2 language: minimal -dist: trusty services: docker install: - docker-compose build diff --git a/spec/support/rspec.rb b/spec/support/rspec.rb index df12fc35..88aec250 100644 --- a/spec/support/rspec.rb +++ b/spec/support/rspec.rb @@ -4,6 +4,8 @@ # spec/spec_helper.rb # +require_relative './locations.rb' + Capybara.register_driver :poltergeist_debug do |app| Capybara::Poltergeist::Driver.new(app, :js_errors => false