diff options
Diffstat (limited to 'activerecord/test/fixtures/mixin.rb')
-rw-r--r-- | activerecord/test/fixtures/mixin.rb | 28 |
1 files changed, 28 insertions, 0 deletions
diff --git a/activerecord/test/fixtures/mixin.rb b/activerecord/test/fixtures/mixin.rb index 5e40c397c0..358dde1ae1 100644 --- a/activerecord/test/fixtures/mixin.rb +++ b/activerecord/test/fixtures/mixin.rb @@ -43,3 +43,31 @@ end class NestedSetSubclass < NestedSetSuperclass end + +class NestedSet < Mixin + acts_as_nested_set :scope => "root_id IS NULL" + + def self.table_name() "mixins" end +end + +class NestedSetWithStringScope < Mixin + acts_as_nested_set :scope => 'root_id = #{root_id}' + + def self.table_name() "mixins" end +end + +class NestedSetWithSymbolScope < Mixin + acts_as_nested_set :scope => :root + + def self.table_name() "mixins" end +end + +class NestedSetSuperclass < Mixin + acts_as_nested_set :scope => :root + + def self.table_name() "mixins" end +end + +class NestedSetSubclass < NestedSetSuperclass + +end |