Skip to content
Browse files

Fixing test for named_scope through a has_many :through

The test that checks if a has_many :through association has access to named_scope had a typo and
didn't have the proper fixtures loaded. [#190 state:resolved]
  • Loading branch information...
1 parent fc02eab commit 5a3fd46d42f05a241b3178af60d38fe5e0cebee6 @divoxx divoxx committed with technoweenie May 13, 2008
Showing with 2 additions and 2 deletions.
  1. +2 −2 activerecord/test/cases/named_scope_test.rb
4 activerecord/test/cases/named_scope_test.rb
@@ -6,7 +6,7 @@
require 'models/author'
class NamedScopeTest < ActiveRecord::TestCase
- fixtures :posts, :authors, :topics
+ fixtures :posts, :authors, :topics, :comments
def test_implements_enumerable
assert !Topic.find(:all).empty?
@@ -95,7 +95,7 @@ def test_has_many_associations_have_access_to_named_scopes
def test_has_many_through_associations_have_access_to_named_scopes
- assert_not_equal Comment.containing_the_letter_e, authors(:david).posts
+ assert_not_equal Comment.containing_the_letter_e, authors(:david).comments
assert !Comment.containing_the_letter_e.empty?
assert_equal authors(:david).comments & Comment.containing_the_letter_e, authors(:david).comments.containing_the_letter_e

0 comments on commit 5a3fd46

Please sign in to comment.
Something went wrong with that request. Please try again.