diff options
author | Emilio Tagua <miloops@gmail.com> | 2009-04-28 18:51:15 -0300 |
---|---|---|
committer | Emilio Tagua <miloops@gmail.com> | 2009-04-28 18:51:15 -0300 |
commit | 1dfae3a5a01b05bf14de88958b625b865748387b (patch) | |
tree | b8e1a63e893a46447bcd593d0f87d7303c9fe0b0 /spec/arel | |
parent | 45646ec54c4c4a3c7340b79deea9e3cf76554f0b (diff) | |
download | rails-1dfae3a5a01b05bf14de88958b625b865748387b.tar.gz rails-1dfae3a5a01b05bf14de88958b625b865748387b.tar.bz2 rails-1dfae3a5a01b05bf14de88958b625b865748387b.zip |
ORDER BY should be included after GROUP BY clause
Diffstat (limited to 'spec/arel')
-rw-r--r-- | spec/arel/unit/relations/alias_spec.rb | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/spec/arel/unit/relations/alias_spec.rb b/spec/arel/unit/relations/alias_spec.rb index 5327154fa8..460a0ed0df 100644 --- a/spec/arel/unit/relations/alias_spec.rb +++ b/spec/arel/unit/relations/alias_spec.rb @@ -5,14 +5,14 @@ module Arel before do @relation = Table.new(:users) end - + describe '==' do it "obtains if the objects are the same" do Alias.new(@relation).should_not == Alias.new(@relation) (aliaz = Alias.new(@relation)).should == aliaz end end - + describe '#to_sql' do describe 'when there is no ambiguity' do it 'does not alias table names anywhere a table name can appear' do @@ -26,11 +26,11 @@ module Arel SELECT `users`.`id` FROM `users` WHERE `users`.`id` = 1 - ORDER BY `users`.`id` GROUP BY `users`.`id` + ORDER BY `users`.`id` ") end end end end -end
\ No newline at end of file +end |