summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--spec/link_spec.rb10
1 files changed, 10 insertions, 0 deletions
diff --git a/spec/link_spec.rb b/spec/link_spec.rb
index 29ecd92..05d7a5c 100644
--- a/spec/link_spec.rb
+++ b/spec/link_spec.rb
@@ -25,6 +25,16 @@ describe EvenDoors::Link do
lnk.cond_value.should eql 'v0v1v2'
end
#
+ it "link->json->link" do
+ link = EvenDoors::Link.new 'input1', 'concat1?follow,output1', 'f0,f2', 'f0,f1,f2', 'v0v1v2'
+ lnk = EvenDoors::Link.json_create( JSON.load( JSON.generate(link) ) )
+ link.src.should eql lnk.src
+ link.dsts.should eql lnk.dsts
+ link.fields.should eql lnk.fields
+ link.cond_fields.should eql lnk.cond_fields
+ link.cond_value.should eql lnk.cond_value
+ end
+ #
end
#
# EOF