diff options
author | Gonçalo Silva <goncalossilva@gmail.com> | 2010-06-30 23:01:30 +0100 |
---|---|---|
committer | Gonçalo Silva <goncalossilva@gmail.com> | 2010-06-30 23:01:30 +0100 |
commit | d2c633ba0bfb7baacdee89a46d7d036d24c68817 (patch) | |
tree | 8f0974852b51597652e6ae73da26f3eb80fe878b /activerecord/test/cases/named_scope_test.rb | |
parent | 92c0f17d6d2a958d3a6285b0e5408e9e0e7122e1 (diff) | |
parent | c63cf7bf0db708fe46a929cf57649ab5a92034af (diff) | |
download | rails-d2c633ba0bfb7baacdee89a46d7d036d24c68817.tar.gz rails-d2c633ba0bfb7baacdee89a46d7d036d24c68817.tar.bz2 rails-d2c633ba0bfb7baacdee89a46d7d036d24c68817.zip |
Merge branch 'master' of http://github.com/rails/rails
Diffstat (limited to 'activerecord/test/cases/named_scope_test.rb')
-rw-r--r-- | activerecord/test/cases/named_scope_test.rb | 10 |
1 files changed, 8 insertions, 2 deletions
diff --git a/activerecord/test/cases/named_scope_test.rb b/activerecord/test/cases/named_scope_test.rb index 33ffb041c1..dc85b395d3 100644 --- a/activerecord/test/cases/named_scope_test.rb +++ b/activerecord/test/cases/named_scope_test.rb @@ -54,8 +54,8 @@ class NamedScopeTest < ActiveRecord::TestCase end def test_respond_to_respects_include_private_parameter - assert !Topic.approved.respond_to?(:with_create_scope) - assert Topic.approved.respond_to?(:with_create_scope, true) + assert !Topic.approved.respond_to?(:tables_in_string) + assert Topic.approved.respond_to?(:tables_in_string, true) end def test_subclasses_inherit_scopes @@ -450,6 +450,12 @@ class NamedScopeTest < ActiveRecord::TestCase assert before.object_id != post.comments.containing_the_letter_e.object_id, "AssociationCollection##{method} should reset the named scopes cache" end end + + def test_named_scoped_are_lazy_loaded_if_table_still_does_not_exist + assert_nothing_raised do + require "models/without_table" + end + end end class DynamicScopeMatchTest < ActiveRecord::TestCase |