acts_as_ordered_tree 1.3.1 → 2.0.0.beta3

Sign up to get free protection for your applications and to get access to all the features.
Files changed (100) hide show
  1. checksums.yaml +4 -4
  2. data/lib/acts_as_ordered_tree.rb +22 -100
  3. data/lib/acts_as_ordered_tree/adapters.rb +17 -0
  4. data/lib/acts_as_ordered_tree/adapters/abstract.rb +23 -0
  5. data/lib/acts_as_ordered_tree/adapters/postgresql.rb +150 -0
  6. data/lib/acts_as_ordered_tree/adapters/recursive.rb +157 -0
  7. data/lib/acts_as_ordered_tree/compatibility.rb +22 -0
  8. data/lib/acts_as_ordered_tree/compatibility/active_record/association_scope.rb +9 -0
  9. data/lib/acts_as_ordered_tree/compatibility/active_record/default_scoped.rb +19 -0
  10. data/lib/acts_as_ordered_tree/compatibility/active_record/null_relation.rb +71 -0
  11. data/lib/acts_as_ordered_tree/compatibility/features.rb +153 -0
  12. data/lib/acts_as_ordered_tree/deprecate.rb +24 -0
  13. data/lib/acts_as_ordered_tree/hooks.rb +38 -0
  14. data/lib/acts_as_ordered_tree/hooks/update.rb +86 -0
  15. data/lib/acts_as_ordered_tree/instance_methods.rb +92 -453
  16. data/lib/acts_as_ordered_tree/iterators/arranger.rb +35 -0
  17. data/lib/acts_as_ordered_tree/iterators/level_calculator.rb +52 -0
  18. data/lib/acts_as_ordered_tree/iterators/orphans_pruner.rb +58 -0
  19. data/lib/acts_as_ordered_tree/node.rb +78 -0
  20. data/lib/acts_as_ordered_tree/node/attributes.rb +48 -0
  21. data/lib/acts_as_ordered_tree/node/movement.rb +62 -0
  22. data/lib/acts_as_ordered_tree/node/movements.rb +111 -0
  23. data/lib/acts_as_ordered_tree/node/predicates.rb +98 -0
  24. data/lib/acts_as_ordered_tree/node/reloading.rb +49 -0
  25. data/lib/acts_as_ordered_tree/node/siblings.rb +139 -0
  26. data/lib/acts_as_ordered_tree/node/traversals.rb +53 -0
  27. data/lib/acts_as_ordered_tree/persevering_transaction.rb +93 -0
  28. data/lib/acts_as_ordered_tree/position.rb +143 -0
  29. data/lib/acts_as_ordered_tree/relation/arrangeable.rb +33 -0
  30. data/lib/acts_as_ordered_tree/relation/iterable.rb +41 -0
  31. data/lib/acts_as_ordered_tree/relation/preloaded.rb +46 -11
  32. data/lib/acts_as_ordered_tree/transaction/base.rb +57 -0
  33. data/lib/acts_as_ordered_tree/transaction/callbacks.rb +67 -0
  34. data/lib/acts_as_ordered_tree/transaction/create.rb +68 -0
  35. data/lib/acts_as_ordered_tree/transaction/destroy.rb +34 -0
  36. data/lib/acts_as_ordered_tree/transaction/dsl.rb +214 -0
  37. data/lib/acts_as_ordered_tree/transaction/factory.rb +67 -0
  38. data/lib/acts_as_ordered_tree/transaction/move.rb +70 -0
  39. data/lib/acts_as_ordered_tree/transaction/passthrough.rb +12 -0
  40. data/lib/acts_as_ordered_tree/transaction/reorder.rb +42 -0
  41. data/lib/acts_as_ordered_tree/transaction/save.rb +64 -0
  42. data/lib/acts_as_ordered_tree/transaction/update.rb +78 -0
  43. data/lib/acts_as_ordered_tree/tree.rb +148 -0
  44. data/lib/acts_as_ordered_tree/tree/association.rb +20 -0
  45. data/lib/acts_as_ordered_tree/tree/callbacks.rb +57 -0
  46. data/lib/acts_as_ordered_tree/tree/children_association.rb +120 -0
  47. data/lib/acts_as_ordered_tree/tree/columns.rb +102 -0
  48. data/lib/acts_as_ordered_tree/tree/deprecated_columns_accessors.rb +24 -0
  49. data/lib/acts_as_ordered_tree/tree/parent_association.rb +31 -0
  50. data/lib/acts_as_ordered_tree/tree/perseverance.rb +19 -0
  51. data/lib/acts_as_ordered_tree/tree/scopes.rb +56 -0
  52. data/lib/acts_as_ordered_tree/validators.rb +1 -1
  53. data/lib/acts_as_ordered_tree/version.rb +1 -1
  54. data/spec/acts_as_ordered_tree_spec.rb +80 -909
  55. data/spec/adapters/postgresql_spec.rb +14 -0
  56. data/spec/adapters/recursive_spec.rb +12 -0
  57. data/spec/adapters/shared.rb +272 -0
  58. data/spec/callbacks_spec.rb +177 -0
  59. data/spec/counter_cache_spec.rb +31 -0
  60. data/spec/create_spec.rb +110 -0
  61. data/spec/destroy_spec.rb +57 -0
  62. data/spec/inheritance_spec.rb +176 -0
  63. data/spec/move_spec.rb +94 -0
  64. data/spec/node/movements/concurrent_movements_spec.rb +354 -0
  65. data/spec/node/movements/move_higher_spec.rb +46 -0
  66. data/spec/node/movements/move_lower_spec.rb +46 -0
  67. data/spec/node/movements/move_to_child_of_spec.rb +147 -0
  68. data/spec/node/movements/move_to_child_with_index_spec.rb +124 -0
  69. data/spec/node/movements/move_to_child_with_position_spec.rb +85 -0
  70. data/spec/node/movements/move_to_left_of_spec.rb +120 -0
  71. data/spec/node/movements/move_to_right_of_spec.rb +120 -0
  72. data/spec/node/movements/move_to_root_spec.rb +67 -0
  73. data/spec/node/predicates_spec.rb +211 -0
  74. data/spec/node/reloading_spec.rb +42 -0
  75. data/spec/node/siblings_spec.rb +193 -0
  76. data/spec/node/traversals_spec.rb +71 -0
  77. data/spec/persevering_transaction_spec.rb +98 -0
  78. data/spec/relation/arrangeable_spec.rb +88 -0
  79. data/spec/relation/iterable_spec.rb +104 -0
  80. data/spec/relation/preloaded_spec.rb +57 -0
  81. data/spec/reorder_spec.rb +83 -0
  82. data/spec/spec_helper.rb +30 -38
  83. data/spec/support/db/boot.rb +22 -0
  84. data/spec/{db → support/db}/config.travis.yml +2 -0
  85. data/spec/{db → support/db}/config.yml +1 -0
  86. data/spec/{db → support/db}/schema.rb +9 -0
  87. data/spec/support/factories.rb +2 -2
  88. data/spec/support/matchers.rb +67 -58
  89. data/spec/support/models.rb +6 -14
  90. data/spec/support/tree_factory.rb +315 -0
  91. data/spec/tree/children_association_spec.rb +72 -0
  92. data/spec/tree/columns_spec.rb +65 -0
  93. data/spec/tree/scopes_spec.rb +39 -0
  94. metadata +161 -43
  95. data/lib/acts_as_ordered_tree/adapters/postgresql_adapter.rb +0 -104
  96. data/lib/acts_as_ordered_tree/arrangeable.rb +0 -80
  97. data/lib/acts_as_ordered_tree/class_methods.rb +0 -72
  98. data/lib/acts_as_ordered_tree/relation/base.rb +0 -26
  99. data/lib/acts_as_ordered_tree/tenacious_transaction.rb +0 -30
  100. data/spec/concurrency_support_spec.rb +0 -156
@@ -0,0 +1,72 @@
1
+ # coding: utf-8
2
+
3
+ require 'spec_helper'
4
+
5
+ # All these examples throw deprecation errors with Rails 4.2
6
+ describe ActsAsOrderedTree::Tree::ChildrenAssociation, :transactional do
7
+ shared_examples 'ChildrenAssociation' do |model|
8
+ describe model.to_s do
9
+ around(:each) do |example|
10
+ ActiveSupport::Deprecation.silence(&example)
11
+ end
12
+
13
+ tree :factory => model do
14
+ root {
15
+ child_1
16
+ child_2
17
+ child_3
18
+ }
19
+ end
20
+
21
+ let(:klass) { current_tree }
22
+
23
+ describe 'joining to association' do
24
+ let(:relation) { klass.joins(:children) }
25
+
26
+ it { expect(relation).to eq [root, root, root] }
27
+ end
28
+
29
+ describe 'loading association' do
30
+ it { expect(root.children.size).to eq 3 }
31
+ it { expect(root.children).to eq [child_1, child_2, child_3] }
32
+
33
+ it { expect{root.children.to_a}.to query_database(/ORDER BY .*position/) }
34
+ end
35
+
36
+ describe 'eager_loading association' do
37
+ let(:relation) { klass.eager_load(:children).order(klass.arel_table[:id]) }
38
+ let(:first) { relation.to_a.first }
39
+
40
+ it { expect(relation).to eq [root, child_1, child_2, child_3] }
41
+ it { expect(first.children).to be_loaded }
42
+ it { expect(first.children.size).to eq 3 }
43
+ end
44
+
45
+ describe 'preloading association' do
46
+ let(:relation) { klass.preload(:children).order(klass.arel_table[:id]) }
47
+ let(:first) { relation.to_a.first }
48
+
49
+ it { expect(relation).to eq [root, child_1, child_2, child_3] }
50
+ it { expect(first.children).to be_loaded }
51
+ it { expect(first.children.size).to eq 3 }
52
+ end
53
+
54
+ describe 'preloading association (via includes method)' do
55
+ let(:relation) { klass.includes(:children).order(klass.arel_table[:id]) }
56
+ let(:first) { relation.to_a.first }
57
+
58
+ it { expect(relation).to eq [root, child_1, child_2, child_3] }
59
+ it { expect(first.children).to be_loaded }
60
+ it { expect(first.children.size).to eq 3 }
61
+ end
62
+
63
+ describe 'extensions' do
64
+ it { expect(root.children).to respond_to :each_with_level }
65
+ it { expect(root.children).to respond_to :each_without_orphans }
66
+ end
67
+ end
68
+ end
69
+
70
+ include_examples 'ChildrenAssociation', :default
71
+ include_examples 'ChildrenAssociation', :scoped
72
+ end
@@ -0,0 +1,65 @@
1
+ # coding: utf-8
2
+
3
+ require 'spec_helper'
4
+
5
+ require 'acts_as_ordered_tree/tree'
6
+
7
+ describe ActsAsOrderedTree::Tree::Columns do
8
+ let(:klass) { Default }
9
+
10
+ shared_examples 'ordered tree column' do |method, option_name, value, klass=Default|
11
+ context 'when existing column name given' do
12
+ subject(:columns) { described_class.new(klass, option_name => value) }
13
+
14
+ it { expect(columns.send(method)).to eq value.to_s }
15
+ it { expect(columns.send("#{method}?")).to be true }
16
+ end
17
+
18
+ context 'when column name given but klass.columns_hash does not contain given name' do
19
+ subject(:columns) { described_class.new(klass, method => :x) }
20
+
21
+ it { expect(columns.send(method)).to be nil }
22
+ it { expect(columns.send("#{method}?")).to be false }
23
+ end
24
+
25
+ context 'when column name not given' do
26
+ subject(:columns) { described_class.new(klass, {}) }
27
+
28
+ it { expect(columns.send(method)).to be nil }
29
+ it { expect(columns.send("#{method}?")).to be false }
30
+ end
31
+
32
+ context 'when false given' do
33
+ subject(:columns) { described_class.new(klass, option_name => false) }
34
+
35
+ it { expect(columns.send(method)).to be nil }
36
+ it { expect(columns.send("#{method}?")).to be false }
37
+ end
38
+ end
39
+
40
+ include_examples 'ordered tree column', :parent, :parent_column, :parent_id
41
+ include_examples 'ordered tree column', :position, :position_column, :position
42
+ include_examples 'ordered tree column', :depth, :depth_column, :depth
43
+ include_examples 'ordered tree column', :counter_cache, :counter_cache, :categories_count do
44
+ context 'when true value as column name given' do
45
+ class Category < ActiveRecord::Base
46
+ end
47
+
48
+ subject(:columns) { described_class.new(Category, :counter_cache => true) }
49
+
50
+ it { expect(columns.counter_cache).to eq 'categories_count' }
51
+ end
52
+ end
53
+
54
+ describe 'scope columns' do
55
+ it 'raises error when any unknown column given' do
56
+ expect{described_class.new(Scoped, :scope => :x)}.to raise_error(described_class::UnknownColumn)
57
+ end
58
+
59
+ it 'returns array' do
60
+ subject = described_class.new(Scoped, :scope => :scope_type)
61
+
62
+ expect(subject.scope).to eq %w(scope_type)
63
+ end
64
+ end
65
+ end
@@ -0,0 +1,39 @@
1
+ # coding: utf-8
2
+
3
+ require 'spec_helper'
4
+
5
+ describe ActsAsOrderedTree::Tree::Scopes, :transactional do
6
+ shared_examples 'ActsAsOrderedTree scopes' do |model, attrs = {}|
7
+ describe model.to_s do
8
+ tree :factory => model, :attributes => attrs do
9
+ root_1 {
10
+ child_1 {
11
+ grandchild_1
12
+ }
13
+ }
14
+ root_2 {
15
+ child_2 {
16
+ grandchild_2
17
+ }
18
+ }
19
+ end
20
+
21
+ describe '.leaves' do
22
+ it { expect(current_tree.leaves.order(:id)).to eq [grandchild_1, grandchild_2] }
23
+ it { expect(root_1.descendants.leaves).to eq [grandchild_1] }
24
+ end
25
+
26
+ describe '.roots' do
27
+ it { expect(current_tree.roots).to eq [root_1, root_2] }
28
+ end
29
+
30
+ describe '.root' do
31
+ it { expect(current_tree.root).to eq root_1 }
32
+ end
33
+ end
34
+ end
35
+
36
+ include_examples 'ActsAsOrderedTree scopes', :default
37
+ include_examples 'ActsAsOrderedTree scopes', :default_with_counter_cache
38
+ include_examples 'ActsAsOrderedTree scopes', :scoped
39
+ end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: acts_as_ordered_tree
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.3.1
4
+ version: 2.0.0.beta3
5
5
  platform: ruby
6
6
  authors:
7
7
  - Alexei Mikhailov
@@ -9,7 +9,7 @@ authors:
9
9
  autorequire:
10
10
  bindir: bin
11
11
  cert_chain: []
12
- date: 2014-02-18 00:00:00.000000000 Z
12
+ date: 2014-12-29 00:00:00.000000000 Z
13
13
  dependencies:
14
14
  - !ruby/object:Gem::Dependency
15
15
  name: activerecord
@@ -17,98 +17,112 @@ dependencies:
17
17
  requirements:
18
18
  - - '>='
19
19
  - !ruby/object:Gem::Version
20
- version: 3.0.0
20
+ version: 3.1.0
21
21
  type: :runtime
22
22
  prerelease: false
23
23
  version_requirements: !ruby/object:Gem::Requirement
24
24
  requirements:
25
25
  - - '>='
26
26
  - !ruby/object:Gem::Version
27
- version: 3.0.0
27
+ version: 3.1.0
28
+ - !ruby/object:Gem::Dependency
29
+ name: activerecord-hierarchical_query
30
+ requirement: !ruby/object:Gem::Requirement
31
+ requirements:
32
+ - - ~>
33
+ - !ruby/object:Gem::Version
34
+ version: 0.0.7
35
+ type: :runtime
36
+ prerelease: false
37
+ version_requirements: !ruby/object:Gem::Requirement
38
+ requirements:
39
+ - - ~>
40
+ - !ruby/object:Gem::Version
41
+ version: 0.0.7
28
42
  - !ruby/object:Gem::Dependency
29
43
  name: rake
30
44
  requirement: !ruby/object:Gem::Requirement
31
45
  requirements:
32
- - - '>='
46
+ - - ~>
33
47
  - !ruby/object:Gem::Version
34
- version: 0.9.2
48
+ version: 10.3.2
35
49
  type: :development
36
50
  prerelease: false
37
51
  version_requirements: !ruby/object:Gem::Requirement
38
52
  requirements:
39
- - - '>='
53
+ - - ~>
40
54
  - !ruby/object:Gem::Version
41
- version: 0.9.2
55
+ version: 10.3.2
42
56
  - !ruby/object:Gem::Dependency
43
57
  name: bundler
44
58
  requirement: !ruby/object:Gem::Requirement
45
59
  requirements:
46
- - - '>='
60
+ - - ~>
47
61
  - !ruby/object:Gem::Version
48
- version: '1.0'
62
+ version: '1.5'
49
63
  type: :development
50
64
  prerelease: false
51
65
  version_requirements: !ruby/object:Gem::Requirement
52
66
  requirements:
53
- - - '>='
67
+ - - ~>
54
68
  - !ruby/object:Gem::Version
55
- version: '1.0'
69
+ version: '1.5'
56
70
  - !ruby/object:Gem::Dependency
57
71
  name: rspec
58
72
  requirement: !ruby/object:Gem::Requirement
59
73
  requirements:
60
- - - '>='
74
+ - - ~>
61
75
  - !ruby/object:Gem::Version
62
- version: '2.11'
76
+ version: 2.99.0
63
77
  type: :development
64
78
  prerelease: false
65
79
  version_requirements: !ruby/object:Gem::Requirement
66
80
  requirements:
67
- - - '>='
81
+ - - ~>
68
82
  - !ruby/object:Gem::Version
69
- version: '2.11'
83
+ version: 2.99.0
70
84
  - !ruby/object:Gem::Dependency
71
- name: shoulda-matchers
85
+ name: database_cleaner
72
86
  requirement: !ruby/object:Gem::Requirement
73
87
  requirements:
74
- - - '>='
88
+ - - ~>
75
89
  - !ruby/object:Gem::Version
76
- version: 2.4.0
90
+ version: 1.3.0
77
91
  type: :development
78
92
  prerelease: false
79
93
  version_requirements: !ruby/object:Gem::Requirement
80
94
  requirements:
81
- - - '>='
95
+ - - ~>
82
96
  - !ruby/object:Gem::Version
83
- version: 2.4.0
97
+ version: 1.3.0
84
98
  - !ruby/object:Gem::Dependency
85
99
  name: factory_girl
86
100
  requirement: !ruby/object:Gem::Requirement
87
101
  requirements:
88
- - - <
102
+ - - ~>
89
103
  - !ruby/object:Gem::Version
90
- version: '3'
104
+ version: 4.4.0
91
105
  type: :development
92
106
  prerelease: false
93
107
  version_requirements: !ruby/object:Gem::Requirement
94
108
  requirements:
95
- - - <
109
+ - - ~>
96
110
  - !ruby/object:Gem::Version
97
- version: '3'
111
+ version: 4.4.0
98
112
  - !ruby/object:Gem::Dependency
99
113
  name: appraisal
100
114
  requirement: !ruby/object:Gem::Requirement
101
115
  requirements:
102
116
  - - '>='
103
117
  - !ruby/object:Gem::Version
104
- version: 0.4.0
118
+ version: 1.0.2
105
119
  type: :development
106
120
  prerelease: false
107
121
  version_requirements: !ruby/object:Gem::Requirement
108
122
  requirements:
109
123
  - - '>='
110
124
  - !ruby/object:Gem::Version
111
- version: 0.4.0
125
+ version: 1.0.2
112
126
  description:
113
127
  email:
114
128
  - amikhailov83@gmail.com
@@ -118,24 +132,97 @@ extensions: []
118
132
  extra_rdoc_files: []
119
133
  files:
120
134
  - lib/acts_as_ordered_tree.rb
121
- - lib/acts_as_ordered_tree/adapters/postgresql_adapter.rb
122
- - lib/acts_as_ordered_tree/arrangeable.rb
123
- - lib/acts_as_ordered_tree/class_methods.rb
135
+ - lib/acts_as_ordered_tree/adapters.rb
136
+ - lib/acts_as_ordered_tree/adapters/abstract.rb
137
+ - lib/acts_as_ordered_tree/adapters/postgresql.rb
138
+ - lib/acts_as_ordered_tree/adapters/recursive.rb
139
+ - lib/acts_as_ordered_tree/compatibility.rb
140
+ - lib/acts_as_ordered_tree/compatibility/active_record/association_scope.rb
141
+ - lib/acts_as_ordered_tree/compatibility/active_record/default_scoped.rb
142
+ - lib/acts_as_ordered_tree/compatibility/active_record/null_relation.rb
143
+ - lib/acts_as_ordered_tree/compatibility/features.rb
144
+ - lib/acts_as_ordered_tree/deprecate.rb
145
+ - lib/acts_as_ordered_tree/hooks.rb
146
+ - lib/acts_as_ordered_tree/hooks/update.rb
124
147
  - lib/acts_as_ordered_tree/instance_methods.rb
125
- - lib/acts_as_ordered_tree/relation/base.rb
148
+ - lib/acts_as_ordered_tree/iterators/arranger.rb
149
+ - lib/acts_as_ordered_tree/iterators/level_calculator.rb
150
+ - lib/acts_as_ordered_tree/iterators/orphans_pruner.rb
151
+ - lib/acts_as_ordered_tree/node.rb
152
+ - lib/acts_as_ordered_tree/node/attributes.rb
153
+ - lib/acts_as_ordered_tree/node/movement.rb
154
+ - lib/acts_as_ordered_tree/node/movements.rb
155
+ - lib/acts_as_ordered_tree/node/predicates.rb
156
+ - lib/acts_as_ordered_tree/node/reloading.rb
157
+ - lib/acts_as_ordered_tree/node/siblings.rb
158
+ - lib/acts_as_ordered_tree/node/traversals.rb
159
+ - lib/acts_as_ordered_tree/persevering_transaction.rb
160
+ - lib/acts_as_ordered_tree/position.rb
161
+ - lib/acts_as_ordered_tree/relation/arrangeable.rb
162
+ - lib/acts_as_ordered_tree/relation/iterable.rb
126
163
  - lib/acts_as_ordered_tree/relation/preloaded.rb
127
- - lib/acts_as_ordered_tree/tenacious_transaction.rb
164
+ - lib/acts_as_ordered_tree/transaction/base.rb
165
+ - lib/acts_as_ordered_tree/transaction/callbacks.rb
166
+ - lib/acts_as_ordered_tree/transaction/create.rb
167
+ - lib/acts_as_ordered_tree/transaction/destroy.rb
168
+ - lib/acts_as_ordered_tree/transaction/dsl.rb
169
+ - lib/acts_as_ordered_tree/transaction/factory.rb
170
+ - lib/acts_as_ordered_tree/transaction/move.rb
171
+ - lib/acts_as_ordered_tree/transaction/passthrough.rb
172
+ - lib/acts_as_ordered_tree/transaction/reorder.rb
173
+ - lib/acts_as_ordered_tree/transaction/save.rb
174
+ - lib/acts_as_ordered_tree/transaction/update.rb
175
+ - lib/acts_as_ordered_tree/tree.rb
176
+ - lib/acts_as_ordered_tree/tree/association.rb
177
+ - lib/acts_as_ordered_tree/tree/callbacks.rb
178
+ - lib/acts_as_ordered_tree/tree/children_association.rb
179
+ - lib/acts_as_ordered_tree/tree/columns.rb
180
+ - lib/acts_as_ordered_tree/tree/deprecated_columns_accessors.rb
181
+ - lib/acts_as_ordered_tree/tree/parent_association.rb
182
+ - lib/acts_as_ordered_tree/tree/perseverance.rb
183
+ - lib/acts_as_ordered_tree/tree/scopes.rb
128
184
  - lib/acts_as_ordered_tree/validators.rb
129
185
  - lib/acts_as_ordered_tree/version.rb
130
186
  - spec/acts_as_ordered_tree_spec.rb
131
- - spec/concurrency_support_spec.rb
132
- - spec/db/config.travis.yml
133
- - spec/db/config.yml
134
- - spec/db/schema.rb
187
+ - spec/adapters/postgresql_spec.rb
188
+ - spec/adapters/recursive_spec.rb
189
+ - spec/adapters/shared.rb
190
+ - spec/callbacks_spec.rb
191
+ - spec/counter_cache_spec.rb
192
+ - spec/create_spec.rb
193
+ - spec/destroy_spec.rb
194
+ - spec/inheritance_spec.rb
195
+ - spec/move_spec.rb
196
+ - spec/node/movements/concurrent_movements_spec.rb
197
+ - spec/node/movements/move_higher_spec.rb
198
+ - spec/node/movements/move_lower_spec.rb
199
+ - spec/node/movements/move_to_child_of_spec.rb
200
+ - spec/node/movements/move_to_child_with_index_spec.rb
201
+ - spec/node/movements/move_to_child_with_position_spec.rb
202
+ - spec/node/movements/move_to_left_of_spec.rb
203
+ - spec/node/movements/move_to_right_of_spec.rb
204
+ - spec/node/movements/move_to_root_spec.rb
205
+ - spec/node/predicates_spec.rb
206
+ - spec/node/reloading_spec.rb
207
+ - spec/node/siblings_spec.rb
208
+ - spec/node/traversals_spec.rb
209
+ - spec/persevering_transaction_spec.rb
210
+ - spec/relation/arrangeable_spec.rb
211
+ - spec/relation/iterable_spec.rb
212
+ - spec/relation/preloaded_spec.rb
213
+ - spec/reorder_spec.rb
135
214
  - spec/spec_helper.rb
215
+ - spec/support/db/boot.rb
216
+ - spec/support/db/config.travis.yml
217
+ - spec/support/db/config.yml
218
+ - spec/support/db/schema.rb
136
219
  - spec/support/factories.rb
137
220
  - spec/support/matchers.rb
138
221
  - spec/support/models.rb
222
+ - spec/support/tree_factory.rb
223
+ - spec/tree/children_association_spec.rb
224
+ - spec/tree/columns_spec.rb
225
+ - spec/tree/scopes_spec.rb
139
226
  homepage: https://github.com/take-five/acts_as_ordered_tree
140
227
  licenses: []
141
228
  metadata: {}
@@ -150,22 +237,53 @@ required_ruby_version: !ruby/object:Gem::Requirement
150
237
  version: '0'
151
238
  required_rubygems_version: !ruby/object:Gem::Requirement
152
239
  requirements:
153
- - - '>='
240
+ - - '>'
154
241
  - !ruby/object:Gem::Version
155
- version: '0'
242
+ version: 1.3.1
156
243
  requirements: []
157
244
  rubyforge_project: acts_as_ordered_tree
158
- rubygems_version: 2.1.11
245
+ rubygems_version: 2.2.2
159
246
  signing_key:
160
247
  specification_version: 4
161
248
  summary: ActiveRecord extension for sorted adjacency lists support
162
249
  test_files:
163
250
  - spec/acts_as_ordered_tree_spec.rb
164
- - spec/concurrency_support_spec.rb
165
- - spec/db/config.travis.yml
166
- - spec/db/config.yml
167
- - spec/db/schema.rb
251
+ - spec/adapters/postgresql_spec.rb
252
+ - spec/adapters/recursive_spec.rb
253
+ - spec/adapters/shared.rb
254
+ - spec/callbacks_spec.rb
255
+ - spec/counter_cache_spec.rb
256
+ - spec/create_spec.rb
257
+ - spec/destroy_spec.rb
258
+ - spec/inheritance_spec.rb
259
+ - spec/move_spec.rb
260
+ - spec/node/movements/concurrent_movements_spec.rb
261
+ - spec/node/movements/move_higher_spec.rb
262
+ - spec/node/movements/move_lower_spec.rb
263
+ - spec/node/movements/move_to_child_of_spec.rb
264
+ - spec/node/movements/move_to_child_with_index_spec.rb
265
+ - spec/node/movements/move_to_child_with_position_spec.rb
266
+ - spec/node/movements/move_to_left_of_spec.rb
267
+ - spec/node/movements/move_to_right_of_spec.rb
268
+ - spec/node/movements/move_to_root_spec.rb
269
+ - spec/node/predicates_spec.rb
270
+ - spec/node/reloading_spec.rb
271
+ - spec/node/siblings_spec.rb
272
+ - spec/node/traversals_spec.rb
273
+ - spec/persevering_transaction_spec.rb
274
+ - spec/relation/arrangeable_spec.rb
275
+ - spec/relation/iterable_spec.rb
276
+ - spec/relation/preloaded_spec.rb
277
+ - spec/reorder_spec.rb
168
278
  - spec/spec_helper.rb
279
+ - spec/support/db/boot.rb
280
+ - spec/support/db/config.travis.yml
281
+ - spec/support/db/config.yml
282
+ - spec/support/db/schema.rb
169
283
  - spec/support/factories.rb
170
284
  - spec/support/matchers.rb
171
285
  - spec/support/models.rb
286
+ - spec/support/tree_factory.rb
287
+ - spec/tree/children_association_spec.rb
288
+ - spec/tree/columns_spec.rb
289
+ - spec/tree/scopes_spec.rb