aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorMatthew Draper <matthew@trebex.net>2017-06-03 19:01:11 +0930
committerGitHub <noreply@github.com>2017-06-03 19:01:11 +0930
commitc10f4fff494cf3b2bb236f4227ecaf1f3f2e0b7c (patch)
tree2891d99b6d6bf7fd3a1bca0ec3a6d3a102a47285
parent7e2465c6de86b43028685c0de434e60cb21773d0 (diff)
parentbad1a267f1740156729656c5fe4bfb7ba769a481 (diff)
downloadrails-c10f4fff494cf3b2bb236f4227ecaf1f3f2e0b7c.tar.gz
rails-c10f4fff494cf3b2bb236f4227ecaf1f3f2e0b7c.tar.bz2
rails-c10f4fff494cf3b2bb236f4227ecaf1f3f2e0b7c.zip
Merge pull request #29343 from koic/remove_redundant_default_scope_tests
Remove a redundant default_scope tests
-rw-r--r--activerecord/test/cases/relations_test.rb10
1 files changed, 0 insertions, 10 deletions
diff --git a/activerecord/test/cases/relations_test.rb b/activerecord/test/cases/relations_test.rb
index 81173945a3..86f3b0b962 100644
--- a/activerecord/test/cases/relations_test.rb
+++ b/activerecord/test/cases/relations_test.rb
@@ -695,16 +695,6 @@ class RelationTest < ActiveRecord::TestCase
end
end
- def test_default_scope_with_conditions_string
- assert_equal Developer.where(name: "David").map(&:id).sort, DeveloperCalledDavid.all.map(&:id).sort
- assert_nil DeveloperCalledDavid.create!.name
- end
-
- def test_default_scope_with_conditions_hash
- assert_equal Developer.where(name: "Jamis").map(&:id).sort, DeveloperCalledJamis.all.map(&:id).sort
- assert_equal "Jamis", DeveloperCalledJamis.create!.name
- end
-
def test_default_scoping_finder_methods
developers = DeveloperCalledDavid.order("id").map(&:id).sort
assert_equal Developer.where(name: "David").map(&:id).sort, developers