diff options
Diffstat (limited to 'activerecord/test')
-rwxr-xr-x | activerecord/test/base_test.rb | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/activerecord/test/base_test.rb b/activerecord/test/base_test.rb index cbc144f57a..c3ae9a08b9 100755 --- a/activerecord/test/base_test.rb +++ b/activerecord/test/base_test.rb @@ -569,6 +569,12 @@ class BasicsTest < Test::Unit::TestCase end end + if current_adapter?(:MysqlAdapter) + def test_update_all_with_order_and_limit + assert_equal 1, Topic.update_all("content = 'bulk updated!'", nil, :limit => 1, :order => 'id DESC') + end + end + def test_update_many topic_data = { 1 => { "content" => "1 updated" }, 2 => { "content" => "2 updated" } } updated = Topic.update(topic_data.keys, topic_data.values) |