summaryrefslogtreecommitdiffstats
path: root/spec/room_spec.rb
diff options
context:
space:
mode:
Diffstat (limited to 'spec/room_spec.rb')
-rw-r--r--spec/room_spec.rb11
1 files changed, 6 insertions, 5 deletions
diff --git a/spec/room_spec.rb b/spec/room_spec.rb
index 3757951..c0b361e 100644
--- a/spec/room_spec.rb
+++ b/spec/room_spec.rb
@@ -220,15 +220,16 @@ describe Edoors::Room do
attr_reader :count
def receive_p p
@count||=0
+ ['0','1','2'][@count].should == p.next_dst
@count += 1
end
end
door1 = Out.new 'door1', room0
- room0.add_link Edoors::Link.new('door0', 'door1')
- room0.add_link Edoors::Link.new('door0', 'door1', 'keys', {'f0'=>'v0'})
- room0.add_link Edoors::Link.new('door0', 'door1', 'keys', {'f0'=>'v0','f1'=>'v1'})
- room0.add_link Edoors::Link.new('door0', 'door1', 'keys', {'f0'=>'v0','f1'=>'v2'})
- room0.add_link Edoors::Link.new('door0', 'door1', 'keys', {'f0'=>'v0','f2'=>'v1'})
+ room0.add_link Edoors::Link.new('door0', ['door1','0'])
+ room0.add_link Edoors::Link.new('door0', ['door1','1'], 'keys', {'f0'=>'v0'})
+ room0.add_link Edoors::Link.new('door0', ['door1','2'], 'keys', {'f0'=>'v0','f1'=>'v1'})
+ room0.add_link Edoors::Link.new('door0', ['door1','3'], 'keys', {'f0'=>'v0','f1'=>'v2'})
+ room0.add_link Edoors::Link.new('door0', ['door1','4'], 'keys', {'f0'=>'v0','f2'=>'v1'})
p = @spin.require_p Edoors::Particle
p['f0']='v0'
p['f1']='v1'