aboutsummaryrefslogtreecommitdiffstats
path: root/activerecord/test/models/member.rb
diff options
context:
space:
mode:
Diffstat (limited to 'activerecord/test/models/member.rb')
-rw-r--r--activerecord/test/models/member.rb3
1 files changed, 3 insertions, 0 deletions
diff --git a/activerecord/test/models/member.rb b/activerecord/test/models/member.rb
index dc0566d8a7..7693c6e515 100644
--- a/activerecord/test/models/member.rb
+++ b/activerecord/test/models/member.rb
@@ -26,6 +26,9 @@ class Member < ActiveRecord::Base
has_many :current_memberships, -> { where :favourite => true }
has_many :clubs, :through => :current_memberships
+ has_many :tenant_memberships
+ has_many :tenant_clubs, through: :tenant_memberships, class_name: 'Club', source: :club
+
has_one :club_through_many, :through => :current_memberships, :source => :club
belongs_to :admittable, polymorphic: true