spec/rgraph/node_spec.rb in rgraph-0.0.4 vs spec/rgraph/node_spec.rb in rgraph-0.0.5
- old
+ new
@@ -1,10 +1,14 @@
require_relative '../../lib/rgraph/node'
describe Node do
- describe ".new" do
- subject { Node.new(name: "Lucas", node_ids: [00001, "00002", 00003], age: 20) }
- its(:name) { should == "Lucas" }
- its(:node_ids) { should == [00001, "00002", 00003] }
- its(:age) { should == 20 }
+ subject { Node.new(name: "Lucas", id: '1', age: 20) }
+ describe "#new" do
+ its(:name) { should eq "Lucas" }
+ its(:id) { should eq '1' }
+ its(:age) { should eq 20 }
+ end
+
+ describe "#degree" do
+ its(:degree) { should eq 0}
end
end