Skip to content

Commit

Permalink
add a comment for sanity of other people to come
Browse files Browse the repository at this point in the history
  • Loading branch information
tenderlove committed Sep 10, 2013
1 parent e64b5da commit e7facb3
Showing 1 changed file with 8 additions and 0 deletions.
Expand Up @@ -605,6 +605,10 @@ def test_habtm_respects_select_query_method
end end


def test_join_table_alias def test_join_table_alias
# FIXME: `references` has no impact on the aliases generated for the join
# query. The fact that we pass `:developers_projects_join` to `references`
# and that the SQL string contains `developers_projects_join` is merely a
# coincidence.
assert_equal( assert_equal(
3, 3,
Developer.references(:developers_projects_join).merge( Developer.references(:developers_projects_join).merge(
Expand All @@ -615,6 +619,10 @@ def test_join_table_alias
end end


def test_join_with_group def test_join_with_group
# FIXME: `references` has no impact on the aliases generated for the join
# query. The fact that we pass `:developers_projects_join` to `references`
# and that the SQL string contains `developers_projects_join` is merely a
# coincidence.
group = Developer.columns.inject([]) do |g, c| group = Developer.columns.inject([]) do |g, c|
g << "developers.#{c.name}" g << "developers.#{c.name}"
g << "developers_projects_2.#{c.name}" g << "developers_projects_2.#{c.name}"
Expand Down

0 comments on commit e7facb3

Please sign in to comment.