summaryrefslogtreecommitdiffstats
path: root/spec
diff options
context:
space:
mode:
authorJérémy Zurcher <jeremy@asynk.ch>2012-05-08 17:00:59 +0200
committerJérémy Zurcher <jeremy@asynk.ch>2012-05-08 17:00:59 +0200
commit0fccc3b247a7d4e0364cbebc80e89e8797c30e29 (patch)
tree82cb387be84c6131d40008012f98466c59ae05e9 /spec
parent26bca3ff4ad5a99047b7b84aff01323f97b98887 (diff)
downloadedoors-ruby-0fccc3b247a7d4e0364cbebc80e89e8797c30e29.zip
edoors-ruby-0fccc3b247a7d4e0364cbebc80e89e8797c30e29.tar.gz
specs: complete Link coverage
Diffstat (limited to 'spec')
-rw-r--r--spec/evendoors_spec.rb19
1 files changed, 19 insertions, 0 deletions
diff --git a/spec/evendoors_spec.rb b/spec/evendoors_spec.rb
index 8a41548..d90423a 100644
--- a/spec/evendoors_spec.rb
+++ b/spec/evendoors_spec.rb
@@ -212,4 +212,23 @@ describe EvenDoors do
#
end
#
+ describe EvenDoors::Link do
+ #
+ it "from particle data" do
+ p = EvenDoors::Twirl.require_p EvenDoors::Particle
+ p.set_data EvenDoors::LNK_SRC, 'input1'
+ p.set_data EvenDoors::LNK_DSTS, 'concat1?follow,output1'
+ p.set_data EvenDoors::LNK_FIELDS, 'f0,f2'
+ p.set_data EvenDoors::LNK_CONDF, 'f0,f1,f2'
+ p.set_data EvenDoors::LNK_CONDV, 'v0v1v2'
+ lnk = EvenDoors::Link.from_particle_data p
+ lnk.src.should eql 'input1'
+ lnk.dsts.should eql 'concat1?follow,output1'
+ lnk.fields.should eql 'f0,f2'
+ lnk.cond_fields.should eql 'f0,f1,f2'
+ lnk.cond_value.should eql 'v0v1v2'
+ end
+ #
+ end
+ #
end