1
0
Fork 0
mirror of https://github.com/rails/rails.git synced 2022-11-09 12:12:34 -05:00

Add failing test

This commit is contained in:
Oriol Gual 2011-06-08 20:54:27 +02:00
parent 941d5c1f40
commit e174923d29

View file

@ -15,6 +15,10 @@ class RelationScopingTest < ActiveRecord::TestCase
assert_equal Developer.order("id DESC").to_a.reverse, Developer.order("id DESC").reverse_order
end
def test_reverse_order_with_arel_node
assert_equal Developer.order("id DESC").to_a.reverse, Developer.order(Developer.arel_table[:id].desc).reverse_order
end
def test_double_reverse_order_produces_original_order
assert_equal Developer.order("name DESC"), Developer.order("name DESC").reverse_order.reverse_order
end