aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--activesupport/test/file_evented_update_checker_test.rb5
-rwxr-xr-xci/travis.rb10
2 files changed, 13 insertions, 2 deletions
diff --git a/activesupport/test/file_evented_update_checker_test.rb b/activesupport/test/file_evented_update_checker_test.rb
index 071449d399..ec3a7e28f3 100644
--- a/activesupport/test/file_evented_update_checker_test.rb
+++ b/activesupport/test/file_evented_update_checker_test.rb
@@ -5,6 +5,11 @@ require 'file_update_checker_shared_tests'
class FileEventedUpdateCheckerTest < ActiveSupport::TestCase
include FileUpdateCheckerSharedTests
+ def setup
+ skip if ENV['LISTEN'] == '0'
+ super
+ end
+
def new_checker(files = [], dirs = {}, &block)
ActiveSupport::FileEventedUpdateChecker.new(files, dirs, &block).tap do
wait
diff --git a/ci/travis.rb b/ci/travis.rb
index b29e06dd5c..658d66c6b4 100755
--- a/ci/travis.rb
+++ b/ci/travis.rb
@@ -111,8 +111,14 @@ class Build
end
def env
- # Provide extra ENV variables for the build here
- {}
+ if activesupport? && !isolated?
+ # There is a known issue with the listen tests that casuses files to be
+ # incorrectly GC'ed even when they are still in-use. The current is to
+ # only run them in isolation to avoid randomly failing our test suite.
+ { 'LISTEN' => '0' }
+ else
+ {}
+ end
end
def run_bug_report_templates