rubytree 0.8.2 → 0.8.3

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -1,7 +1,5 @@
1
1
  # binarytree.rb - This file is part of the RubyTree package.
2
2
  #
3
- # $Revision$ by $Author$ on $Date$
4
- #
5
3
  # = binarytree.rb - An implementation of the binary tree data structure.
6
4
  #
7
5
  # Provides a binary tree data structure with ability to
@@ -10,7 +8,7 @@
10
8
  # Author:: Anupam Sengupta (anupamsg@gmail.com)
11
9
  #
12
10
 
13
- # Copyright (c) 2007, 2008, 2009, 2010 Anupam Sengupta
11
+ # Copyright (c) 2007, 2008, 2009, 2010, 2012 Anupam Sengupta
14
12
  #
15
13
  # All rights reserved.
16
14
  #
@@ -69,7 +67,8 @@ module Tree
69
67
  super(child)
70
68
  end
71
69
 
72
- # Returns the left child of the receiver node. Note that left Child == first Child.
70
+ # @!attribute [rw] left_child
71
+ # Left child of the receiver node. Note that left Child == first Child.
73
72
  #
74
73
  # @return [Tree::BinaryTreeNode] The left most (or first) child.
75
74
  #
@@ -78,7 +77,8 @@ module Tree
78
77
  children.first
79
78
  end
80
79
 
81
- # Returns the right child of the receiver node. Note that right child == last child unless there is only one child.
80
+ # @!attribute [rw] right_child
81
+ # Right child of the receiver node. Note that right child == last child unless there is only one child.
82
82
  #
83
83
  # Returns +nil+ if the right child does not exist.
84
84
  #
@@ -150,8 +150,6 @@ module Tree
150
150
  end
151
151
 
152
152
  # Swaps the left and right child nodes of the receiver node with each other.
153
- #
154
- # @todo Define the return value.
155
153
  def swap_children
156
154
  self.left_child, self.right_child = self.right_child, self.left_child
157
155
  end
@@ -0,0 +1,41 @@
1
+ # rubytree_deps.rb - This file is part of the RubyTree package.
2
+ #
3
+ # = rubytree_deps.rb - Dependencies for RubyTree
4
+ #
5
+ # Centralizes and lists the dependencies forthe RubyTree gem.
6
+ #
7
+ # Author:: Anupam Sengupta (anupamsg@gmail.com)
8
+ #
9
+
10
+ # Copyright (c) 2006, 2007, 2008, 2009, 2010, 2011, 2012 Anupam Sengupta
11
+ #
12
+ # All rights reserved.
13
+ #
14
+ # Redistribution and use in source and binary forms, with or without modification,
15
+ # are permitted provided that the following conditions are met:
16
+ #
17
+ # - Redistributions of source code must retain the above copyright notice, this
18
+ # list of conditions and the following disclaimer.
19
+ #
20
+ # - Redistributions in binary form must reproduce the above copyright notice, this
21
+ # list of conditions and the following disclaimer in the documentation and/or
22
+ # other materials provided with the distribution.
23
+ #
24
+ # - Neither the name of the organization nor the names of its contributors may
25
+ # be used to endorse or promote products derived from this software without
26
+ # specific prior written permission.
27
+ #
28
+ # THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
29
+ # AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
30
+ # IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
31
+ # DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR
32
+ # ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES
33
+ # (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
34
+ # LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON
35
+ # ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
36
+ # (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
37
+ # SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
38
+ #
39
+
40
+ require 'structured_warnings'
41
+ require 'json'
@@ -0,0 +1,41 @@
1
+ #--
2
+ # version.rb - This file is part of the RubyTree package.
3
+ #
4
+ # This file provides the version number for Rubytree.
5
+ #
6
+ # Author:: Anupam Sengupta (anupamsg@gmail.com)
7
+ #
8
+ # Copyright (c) 2012 Anupam Sengupta
9
+ #
10
+ # All rights reserved.
11
+ #
12
+ # Redistribution and use in source and binary forms, with or without modification,
13
+ # are permitted provided that the following conditions are met:
14
+ #
15
+ # - Redistributions of source code must retain the above copyright notice, this
16
+ # list of conditions and the following disclaimer.
17
+ #
18
+ # - Redistributions in binary form must reproduce the above copyright notice, this
19
+ # list of conditions and the following disclaimer in the documentation and/or
20
+ # other materials provided with the distribution.
21
+ #
22
+ # - Neither the name of the organization nor the names of its contributors may
23
+ # be used to endorse or promote products derived from this software without
24
+ # specific prior written permission.
25
+ #
26
+ # THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
27
+ # AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
28
+ # IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
29
+ # DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR
30
+ # ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES
31
+ # (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
32
+ # LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON
33
+ # ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
34
+ # (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
35
+ # SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
36
+ #
37
+
38
+ module Tree
39
+ # Rubytree Package Version
40
+ VERSION = '0.8.3'
41
+ end
@@ -2,9 +2,8 @@
2
2
 
3
3
  # test_binarytree.rb - This file is part of the RubyTree package.
4
4
  #
5
- # $Revision$ by $Author$ on $Date$
6
5
  #
7
- # Copyright (c) 2006, 2007, 2008, 2009, 2010 Anupam Sengupta
6
+ # Copyright (c) 2006, 2007, 2008, 2009, 2010, 2012 Anupam Sengupta
8
7
  #
9
8
  # All rights reserved.
10
9
  #
@@ -0,0 +1,48 @@
1
+ #!/usr/bin/env ruby
2
+
3
+ # test_rubytree_require.rb - This file is part of the RubyTree package.
4
+ #
5
+ # Copyright (c) 2012 Anupam Sengupta
6
+ #
7
+ # All rights reserved.
8
+ #
9
+ # Redistribution and use in source and binary forms, with or without modification,
10
+ # are permitted provided that the following conditions are met:
11
+ #
12
+ # - Redistributions of source code must retain the above copyright notice, this
13
+ # list of conditions and the following disclaimer.
14
+ #
15
+ # - Redistributions in binary form must reproduce the above copyright notice, this
16
+ # list of conditions and the following disclaimer in the documentation and/or
17
+ # other materials provided with the distribution.
18
+ #
19
+ # - Neither the name of the organization nor the names of its contributors may
20
+ # be used to endorse or promote products derived from this software without
21
+ # specific prior written permission.
22
+ #
23
+ # THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
24
+ # AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
25
+ # IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
26
+ # DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR
27
+ # ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES
28
+ # (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
29
+ # LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON
30
+ # ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
31
+ # (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
32
+ # SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
33
+ #
34
+
35
+ require 'test/unit'
36
+ require 'rubytree'
37
+
38
+ module TestTree
39
+
40
+ # Test class for checking whether require 'rubytree' works.
41
+ class TestRequireRubytree < Test::Unit::TestCase
42
+
43
+ # A simple test. We are just checking whether the require worked.
44
+ def test_create_a_simple_node
45
+ assert_not_nil(Tree::TreeNode.new("Root", "A Root node"))
46
+ end
47
+ end
48
+ end
data/test/test_tree.rb CHANGED
@@ -1,10 +1,8 @@
1
1
  #!/usr/bin/env ruby
2
2
 
3
- # testtree.rb - This file is part of the RubyTree package.
3
+ # test_tree.rb - This file is part of the RubyTree package.
4
4
  #
5
- # $Revision$ by $Author$ on $Date$
6
- #
7
- # Copyright (c) 2006, 2007, 2008, 2009, 2010, 2011 Anupam Sengupta
5
+ # Copyright (c) 2006, 2007, 2008, 2009, 2010, 2011, 2012 Anupam Sengupta
8
6
  #
9
7
  # All rights reserved.
10
8
  #
@@ -35,7 +33,6 @@
35
33
  #
36
34
 
37
35
  require 'test/unit'
38
- require 'rubygems'
39
36
  require 'json'
40
37
  require 'tree'
41
38
 
@@ -88,6 +85,11 @@ module TestTree
88
85
  @root = nil
89
86
  end
90
87
 
88
+ # Test for presence of the VERSION constant
89
+ def test_has_version_number
90
+ assert_not_nil(Tree::VERSION)
91
+ end
92
+
91
93
  # This test is for the root alone - without any children being linked
92
94
  def test_root_setup
93
95
  assert_not_nil(@root , "Root cannot be nil")
@@ -99,7 +101,7 @@ module TestTree
99
101
  assert(!@root.has_children? , "Cannot have any children")
100
102
  assert(@root.has_content? , "This root should have content")
101
103
  assert_equal(1 , @root.size, "Number of nodes should be one")
102
- assert_nil(@root.siblings , "This root does not have any children")
104
+ assert_equal(0, @root.siblings.length, "This root does not have any children")
103
105
  assert_equal(0, @root.in_degree, "Root should have an in-degree of 0")
104
106
  assert_equal(0, @root.node_height, "Root's height before adding any children is 0")
105
107
  assert_raise(ArgumentError) { Tree::TreeNode.new(nil) }
@@ -137,6 +139,9 @@ module TestTree
137
139
 
138
140
  # Test the <=> operator.
139
141
  def test_spaceship
142
+ require 'structured_warnings'
143
+ StandardWarning.disable # Disable the warnings for using integers as node names
144
+
140
145
  first_node = Tree::TreeNode.new(1)
141
146
  second_node = Tree::TreeNode.new(2)
142
147
 
@@ -155,6 +160,8 @@ module TestTree
155
160
 
156
161
  second_node = Tree::TreeNode.new("ABC")
157
162
  assert_equal(first_node <=> second_node, 0)
163
+
164
+ StandardWarning.enable
158
165
  end
159
166
 
160
167
  # Test the to_s method. This is probably a little fragile right now.
@@ -199,6 +206,7 @@ module TestTree
199
206
  assert_same(@child1, @child1.first_sibling, "Child1's first sibling is itself")
200
207
  assert_same(@child1, @child2.first_sibling, "Child2's first sibling should be child1")
201
208
  assert_same(@child1, @child3.first_sibling, "Child3's first sibling should be child1")
209
+ assert_same(@child4, @child4.first_sibling, "Child4's first sibling should be itself")
202
210
  assert_not_same(@child1, @child4.first_sibling, "Child4's first sibling is itself")
203
211
  end
204
212
 
@@ -206,7 +214,6 @@ module TestTree
206
214
  def test_is_first_sibling_eh
207
215
  setup_test_tree
208
216
 
209
- # TODO: Need to fix the first_sibling method to return nil for nodes with no siblings.
210
217
  assert(@root.is_first_sibling?, "Root's first sibling is itself")
211
218
  assert( @child1.is_first_sibling?, "Child1's first sibling is itself")
212
219
  assert(!@child2.is_first_sibling?, "Child2 is not the first sibling")
@@ -218,7 +225,6 @@ module TestTree
218
225
  def test_is_last_sibling_eh
219
226
  setup_test_tree
220
227
 
221
- # TODO: Need to fix the last_sibling method to return nil for nodes with no siblings.
222
228
  assert(@root.is_last_sibling?, "Root's last sibling is itself")
223
229
  assert(!@child1.is_last_sibling?, "Child1 is not the last sibling")
224
230
  assert(!@child2.is_last_sibling?, "Child2 is not the last sibling")
@@ -230,11 +236,11 @@ module TestTree
230
236
  def test_last_sibling
231
237
  setup_test_tree
232
238
 
233
- # TODO: Need to fix the last_sibling method to return nil for nodes with no siblings.
234
239
  assert_same(@root, @root.last_sibling, "Root's last sibling is itself")
235
240
  assert_same(@child3, @child1.last_sibling, "Child1's last sibling should be child3")
236
241
  assert_same(@child3, @child2.last_sibling, "Child2's last sibling should be child3")
237
242
  assert_same(@child3, @child3.last_sibling, "Child3's last sibling should be itself")
243
+ assert_same(@child4, @child4.last_sibling, "Child4's last sibling should be itself")
238
244
  assert_not_same(@child3, @child4.last_sibling, "Child4's last sibling is itself")
239
245
  end
240
246
 
@@ -260,7 +266,7 @@ module TestTree
260
266
 
261
267
  siblings.clear
262
268
  siblings = @root.siblings
263
- assert_nil(siblings, "Root should not have any siblings")
269
+ assert_equal(0, siblings.length, "Root should not have any siblings")
264
270
  end
265
271
 
266
272
  # Test the is_only_child? method.
@@ -1070,6 +1076,62 @@ module TestTree
1070
1076
 
1071
1077
  end
1072
1078
 
1079
+ # Test usage of integers as node names
1080
+ def test_integer_node_names
1081
+
1082
+ require 'structured_warnings'
1083
+ assert_warn(StandardWarning) do
1084
+ @n_root = Tree::TreeNode.new(0, "Root Node")
1085
+ @n_child1 = Tree::TreeNode.new(1, "Child Node 1")
1086
+ @n_child2 = Tree::TreeNode.new(2, "Child Node 2")
1087
+ @n_child3 = Tree::TreeNode.new("three", "Child Node 3")
1088
+ end
1089
+
1090
+ @n_root << @n_child1
1091
+ @n_root << @n_child2
1092
+ @n_root << @n_child3
1093
+
1094
+ # Node[n] is really accessing the nth child with a zero-base
1095
+ assert_not_equal(@n_root[1].name, 1) # This is really the second child
1096
+ assert_equal(@n_root[0].name, 1) # This will work, as it is the first child
1097
+ assert_equal(@n_root[1, true].name, 1) # This will work, as the flag is now enabled
1098
+
1099
+ # Sanity check for the "normal" string name cases. Both cases should work.
1100
+ assert_equal(@n_root["three", false].name, "three")
1101
+
1102
+ StandardWarning.disable
1103
+ assert_equal(@n_root["three", true].name, "three")
1104
+
1105
+ # Also ensure that the warning is actually being thrown
1106
+ StandardWarning.enable
1107
+ assert_warn(StandardWarning) {assert_equal(@n_root["three", true].name, "three") }
1108
+ end
1109
+
1110
+ # Test the addition of a node to itself as a child
1111
+ def test_add_node_to_self_as_child
1112
+ root = Tree::TreeNode.new("root")
1113
+
1114
+ # Lets check the direct parentage scenario
1115
+ assert_raise(ArgumentError) {root << root}
1116
+
1117
+ # And now a scenario where the node addition is done down the hierarchy
1118
+ # @todo This scenario is not yet fixed.
1119
+ child = Tree::TreeNode.new("child")
1120
+ root << child << root
1121
+ # puts root # This will throw a stack trace
1122
+ end
1123
+
1124
+ # Test whether the tree_leaf method works correctly
1125
+ def test_single_node_becomes_leaf
1126
+ setup_test_tree
1127
+
1128
+ leafs = @root.each_leaf
1129
+ parents = leafs.collect {|leaf| leaf.parent }
1130
+ leafs.each {|leaf| leaf.remove_from_parent!}
1131
+ parents.each {|parent| assert(parent.is_leaf?) if not parent.has_children?}
1132
+
1133
+ end
1134
+
1073
1135
  end
1074
1136
  end
1075
1137
 
metadata CHANGED
@@ -1,139 +1,187 @@
1
- --- !ruby/object:Gem::Specification
1
+ --- !ruby/object:Gem::Specification
2
2
  name: rubytree
3
- version: !ruby/object:Gem::Version
4
- hash: 59
3
+ version: !ruby/object:Gem::Version
4
+ version: 0.8.3
5
5
  prerelease:
6
- segments:
7
- - 0
8
- - 8
9
- - 2
10
- version: 0.8.2
11
6
  platform: ruby
12
- authors:
7
+ authors:
13
8
  - Anupam Sengupta
14
9
  autorequire:
15
10
  bindir: bin
16
11
  cert_chain: []
17
-
18
- date: 2011-12-16 00:00:00 Z
19
- dependencies:
20
- - !ruby/object:Gem::Dependency
21
- name: hoe-yard
12
+ date: 2012-08-21 00:00:00.000000000 Z
13
+ dependencies:
14
+ - !ruby/object:Gem::Dependency
15
+ name: structured_warnings
16
+ requirement: !ruby/object:Gem::Requirement
17
+ none: false
18
+ requirements:
19
+ - - ! '>='
20
+ - !ruby/object:Gem::Version
21
+ version: 0.1.3
22
+ type: :runtime
23
+ prerelease: false
24
+ version_requirements: !ruby/object:Gem::Requirement
25
+ none: false
26
+ requirements:
27
+ - - ! '>='
28
+ - !ruby/object:Gem::Version
29
+ version: 0.1.3
30
+ - !ruby/object:Gem::Dependency
31
+ name: json
32
+ requirement: !ruby/object:Gem::Requirement
33
+ none: false
34
+ requirements:
35
+ - - ! '>='
36
+ - !ruby/object:Gem::Version
37
+ version: 1.7.5
38
+ type: :runtime
22
39
  prerelease: false
23
- requirement: &id001 !ruby/object:Gem::Requirement
40
+ version_requirements: !ruby/object:Gem::Requirement
41
+ none: false
42
+ requirements:
43
+ - - ! '>='
44
+ - !ruby/object:Gem::Version
45
+ version: 1.7.5
46
+ - !ruby/object:Gem::Dependency
47
+ name: rake
48
+ requirement: !ruby/object:Gem::Requirement
24
49
  none: false
25
- requirements:
26
- - - ">="
27
- - !ruby/object:Gem::Version
28
- hash: 31
29
- segments:
30
- - 0
31
- - 1
32
- - 2
33
- version: 0.1.2
50
+ requirements:
51
+ - - ! '>='
52
+ - !ruby/object:Gem::Version
53
+ version: 0.9.2.2
34
54
  type: :development
35
- version_requirements: *id001
36
- - !ruby/object:Gem::Dependency
37
- name: hoe
38
55
  prerelease: false
39
- requirement: &id002 !ruby/object:Gem::Requirement
56
+ version_requirements: !ruby/object:Gem::Requirement
57
+ none: false
58
+ requirements:
59
+ - - ! '>='
60
+ - !ruby/object:Gem::Version
61
+ version: 0.9.2.2
62
+ - !ruby/object:Gem::Dependency
63
+ name: yard
64
+ requirement: !ruby/object:Gem::Requirement
40
65
  none: false
41
- requirements:
66
+ requirements:
67
+ - - ! '>='
68
+ - !ruby/object:Gem::Version
69
+ version: 0.8.2.1
70
+ type: :development
71
+ prerelease: false
72
+ version_requirements: !ruby/object:Gem::Requirement
73
+ none: false
74
+ requirements:
75
+ - - ! '>='
76
+ - !ruby/object:Gem::Version
77
+ version: 0.8.2.1
78
+ - !ruby/object:Gem::Dependency
79
+ name: rtagstask
80
+ requirement: !ruby/object:Gem::Requirement
81
+ none: false
82
+ requirements:
83
+ - - ! '>='
84
+ - !ruby/object:Gem::Version
85
+ version: 0.0.4
86
+ type: :development
87
+ prerelease: false
88
+ version_requirements: !ruby/object:Gem::Requirement
89
+ none: false
90
+ requirements:
91
+ - - ! '>='
92
+ - !ruby/object:Gem::Version
93
+ version: 0.0.4
94
+ - !ruby/object:Gem::Dependency
95
+ name: rcov
96
+ requirement: !ruby/object:Gem::Requirement
97
+ none: false
98
+ requirements:
42
99
  - - ~>
43
- - !ruby/object:Gem::Version
44
- hash: 27
45
- segments:
46
- - 2
47
- - 12
48
- version: "2.12"
100
+ - !ruby/object:Gem::Version
101
+ version: 0.9.0
49
102
  type: :development
50
- version_requirements: *id002
51
- description: |-
52
- RubyTree is a Ruby implementation of the generic tree data structure. It provides a node-based model to store keyed
53
- node-elements in the tree and simple APIs to access, modify and traverse the structure. RubyTree is node-centric, where
54
- individual nodes on the tree are the primary compositional and structural elements.
55
-
56
- This implementation also mixes in the Enumerable module to allow standard access to the tree as a collection.
57
- email:
58
- - anupamsg@gmail.com
103
+ prerelease: false
104
+ version_requirements: !ruby/object:Gem::Requirement
105
+ none: false
106
+ requirements:
107
+ - - ~>
108
+ - !ruby/object:Gem::Version
109
+ version: 0.9.0
110
+ description: ! " RubyTree is a Ruby implementation of the generic tree data structure.\n
111
+ \ It provides a node-based model to store uniquely identifiable node-elements
112
+ in\n the tree and simple APIs to access, modify and traverse the structure.\n
113
+ \ RubyTree is node-centric, where individual nodes on the tree are the primary\n
114
+ \ compositional and structural elements.\n\n This implementation also mixes
115
+ in the Enumerable module to allow standard\n access to the tree as a collection.\n"
116
+ email: anupamsg@gmail.com
59
117
  executables: []
60
-
61
118
  extensions: []
62
-
63
- extra_rdoc_files:
64
- - History.txt
65
- - Manifest.txt
66
- - COPYING
67
- - API-CHANGES
68
- files:
69
- - COPYING
70
- - History.txt
71
- - Manifest.txt
72
- - README
73
- - API-CHANGES
74
- - Rakefile
75
- - TODO
76
- - lib/tree.rb
119
+ extra_rdoc_files:
120
+ - README.rdoc
121
+ - COPYING.rdoc
122
+ - API-CHANGES.rdoc
123
+ - History.rdoc
124
+ files:
125
+ - lib/rubytree.rb
77
126
  - lib/tree/binarytree.rb
78
- - setup.rb
127
+ - lib/tree/tree_deps.rb
128
+ - lib/tree/version.rb
129
+ - lib/tree.rb
130
+ - API-CHANGES.rdoc
131
+ - COPYING.rdoc
132
+ - Gemfile
133
+ - Gemfile.lock
134
+ - History.rdoc
135
+ - Rakefile
136
+ - README.rdoc
137
+ - TODO.org
79
138
  - test/test_binarytree.rb
139
+ - test/test_rubytree_require.rb
80
140
  - test/test_tree.rb
141
+ - .dir-locals.el
81
142
  - .gemtest
82
143
  homepage: http://rubytree.rubyforge.org
83
- licenses: []
84
-
85
- post_install_message: |
86
- ========================================================================
87
-
88
- Thank you for installing rubytree.
89
-
90
- WARNING: SIGNIFICANT API CHANGE in 0.8.0 !
91
- ------------------------------------------
92
-
93
- Please note that as of 0.8.0 the CamelCase method names are DEPRECATED.
94
-
95
- The new method names follow the ruby_convention (separated by '_').
96
-
97
- The old CamelCase methods still work (a warning will be displayed),
98
- but may go away in the future.
99
-
100
- Details of the API changes are documented in the API-CHANGES file.
101
-
102
- ========================================================================
103
-
104
- rdoc_options:
105
- - --files
106
- - COPYING,API-CHANGES
144
+ licenses:
145
+ - BSD
146
+ post_install_message: ! " ========================================================================\n
147
+ \ Thank you for installing rubytree.\n\n Note that the TreeNode#siblings
148
+ method has changed in 0.8.3.\n It now returns an empty array for the root node.\n\n
149
+ \ WARNING: SIGNIFICANT API CHANGE in 0.8.0 !\n ------------------------------------------\n\n
150
+ \ Please note that as of 0.8.0 the CamelCase method names are DEPRECATED.\n The
151
+ new method names follow the ruby_convention (separated by '_').\n\n The old CamelCase
152
+ methods still work (a warning will be displayed),\n but may go away in the future.\n\n
153
+ \ Details of the API changes are documented in the API-CHANGES file.\n ========================================================================\n"
154
+ rdoc_options:
107
155
  - --title
108
156
  - Rubytree Documentation
109
157
  - --quiet
110
- require_paths:
158
+ require_paths:
111
159
  - lib
112
- required_ruby_version: !ruby/object:Gem::Requirement
160
+ required_ruby_version: !ruby/object:Gem::Requirement
113
161
  none: false
114
- requirements:
115
- - - ">="
116
- - !ruby/object:Gem::Version
117
- hash: 3
118
- segments:
162
+ requirements:
163
+ - - ! '>='
164
+ - !ruby/object:Gem::Version
165
+ version: '0'
166
+ segments:
119
167
  - 0
120
- version: "0"
121
- required_rubygems_version: !ruby/object:Gem::Requirement
168
+ hash: -2468456900520768695
169
+ required_rubygems_version: !ruby/object:Gem::Requirement
122
170
  none: false
123
- requirements:
124
- - - ">="
125
- - !ruby/object:Gem::Version
126
- hash: 3
127
- segments:
171
+ requirements:
172
+ - - ! '>='
173
+ - !ruby/object:Gem::Version
174
+ version: '0'
175
+ segments:
128
176
  - 0
129
- version: "0"
177
+ hash: -2468456900520768695
130
178
  requirements: []
131
-
132
179
  rubyforge_project: rubytree
133
- rubygems_version: 1.8.10
180
+ rubygems_version: 1.8.24
134
181
  signing_key:
135
182
  specification_version: 3
136
- summary: RubyTree is a Ruby implementation of the generic tree data structure
137
- test_files:
183
+ summary: A generic tree data structure.
184
+ test_files:
138
185
  - test/test_binarytree.rb
186
+ - test/test_rubytree_require.rb
139
187
  - test/test_tree.rb