diff --git a/activerecord/test/cases/base_test.rb b/activerecord/test/cases/base_test.rb index 4e1685f1513d53d2c5c9419b5a4e327111164a42..36754015554040ad269329f0ff6c816def529425 100644 --- a/activerecord/test/cases/base_test.rb +++ b/activerecord/test/cases/base_test.rb @@ -522,6 +522,10 @@ def test_find_by_slug_with_array assert_equal Topic.find(['1-meowmeow', '2-hello']), Topic.find([1, 2]) end + def test_find_by_slug_with_range + assert_equal Topic.where(id: '1-meowmeow'..'2-hello'), Topic.where(id: 1..2) + end + def test_equality_of_new_records assert_not_equal Topic.new, Topic.new assert_equal false, Topic.new == Topic.new