aboutsummaryrefslogtreecommitdiffstats
path: root/activesupport/test/core_ext/load_error_test.rb
diff options
context:
space:
mode:
authorRafael Mendonça França <rafaelmfranca@gmail.com>2014-07-21 14:25:51 -0300
committerRafael Mendonça França <rafaelmfranca@gmail.com>2014-07-21 14:25:51 -0300
commitcee2c85b07317524861ba14b51d8e7e9b34966ba (patch)
tree49aa63b52ade1117fda269ed1dc15fa6fe39834e /activesupport/test/core_ext/load_error_test.rb
parentfae918575fe8d930d71e06dab40254a0e74f480d (diff)
parent3b9cc0a56f4cbfb97f12c5a167ac901f7682bbe2 (diff)
downloadrails-cee2c85b07317524861ba14b51d8e7e9b34966ba.tar.gz
rails-cee2c85b07317524861ba14b51d8e7e9b34966ba.tar.bz2
rails-cee2c85b07317524861ba14b51d8e7e9b34966ba.zip
Merge pull request #16232 from egilburg/activesupport_coverage
Added some missing activesupport test coverage
Diffstat (limited to 'activesupport/test/core_ext/load_error_test.rb')
-rw-r--r--activesupport/test/core_ext/load_error_test.rb11
1 files changed, 10 insertions, 1 deletions
diff --git a/activesupport/test/core_ext/load_error_test.rb b/activesupport/test/core_ext/load_error_test.rb
index 31863d0aca..5f804c749b 100644
--- a/activesupport/test/core_ext/load_error_test.rb
+++ b/activesupport/test/core_ext/load_error_test.rb
@@ -14,6 +14,15 @@ class TestMissingSourceFile < ActiveSupport::TestCase
assert_equal 'nor/this/one.rb', e.path
end
end
+
+ def test_is_missing
+ begin load 'nor_does_this_one'
+ rescue MissingSourceFile => e
+ assert e.is_missing?('nor_does_this_one')
+ assert e.is_missing?('nor_does_this_one.rb')
+ assert_not e.is_missing?('some_other_file')
+ end
+ end
end
class TestLoadError < ActiveSupport::TestCase
@@ -29,4 +38,4 @@ class TestLoadError < ActiveSupport::TestCase
assert_equal 'nor/this/one.rb', e.path
end
end
-end \ No newline at end of file
+end