nutmeg 0.0.7 → 0.0.8
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/lib/nutmeg/tree_from_json.rb +1 -2
- data/lib/nutmeg/version.rb +1 -1
- data/spec/tag_tree_helper_spec.rb +1 -1
- data/spec/tree_from_json_spec.rb +1 -1
- metadata +1 -1
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: fa5c29f2a577c86a36fec11a3188fe85e4ae4133
|
4
|
+
data.tar.gz: dcb623c140e4c6f936d7ca6a5cbd463fd5d2a657
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 1c75765380e498c42d16935e69fdd5a52b9a90809eafe76fab494141e8c89433e1875f193654b77cf58046fedb9a97158135ca376c3d194375189fc2fc9f9cf2
|
7
|
+
data.tar.gz: 09ef6c8ed689511b0781d716178b299c8be55c00ad32d46c99d2cc00fde179120e520d7242591f73f70ae5ccb9252eb0a63d9306789d4f3752e0b88e4e171d9d
|
@@ -3,8 +3,7 @@ module Nutmeg
|
|
3
3
|
attr_accessor :base_tree, :tags, :tree_hash, :tree, :tag_tree
|
4
4
|
|
5
5
|
def initialize(data)
|
6
|
-
@data = data
|
7
|
-
# @tags = @data["tags"]
|
6
|
+
@data = JSON.load(data)
|
8
7
|
@base_tree = @data
|
9
8
|
@tag_tree = Tree::TreeNode.new("ROOT", {:tag => "root",:otag => "root", :level => nil, :slug => "root"})
|
10
9
|
base_tree.each do |node|
|
data/lib/nutmeg/version.rb
CHANGED
@@ -4,7 +4,7 @@ describe Nutmeg::TagTreeHelper do
|
|
4
4
|
|
5
5
|
before(:each) do
|
6
6
|
@tree_from_yaml = Nutmeg::TreeFromYaml.new({file: [Dir.pwd, "/spec/files/tree.yml"].join})
|
7
|
-
data =
|
7
|
+
data = File.open([Dir.pwd, "/spec/files/tree.json"].join)
|
8
8
|
@tree_from_json = Nutmeg::TreeFromJson.new(data)
|
9
9
|
end
|
10
10
|
|
data/spec/tree_from_json_spec.rb
CHANGED
@@ -3,7 +3,7 @@ require 'spec_helper'
|
|
3
3
|
describe Nutmeg::TreeFromJson do
|
4
4
|
|
5
5
|
before(:each) do
|
6
|
-
data =
|
6
|
+
data = File.open([Dir.pwd, "/spec/files/tree.json"].join).read
|
7
7
|
@tree_from_json = Nutmeg::TreeFromJson.new(data)
|
8
8
|
end
|
9
9
|
|