Sha256: ee3a60f63148835a2d6bf8fc08c5583ef01a305e3237198df493ebf26f504fc9

Contents?: true

Size: 413 Bytes

Versions: 1

Compression:

Stored size: 413 Bytes

Contents

if false

$: << File.expand_path("../..",__FILE__)
require File.expand_path("../../routing.rb",__FILE__)

describe "Nodes" do
  it "should compute the shortest path" do
    ns=Nodes.new(30)
    ns.computeDistances
    
    
    a=ns.nodes[0]
    b=ns.nodes[1]
    
    p=ns.shortestPath(a,b)
    puts a,b,p,p.nodes
    
    p.value.should == a.distance(b)
    a.distance(b).should == b.distance(a)
  end
end#

end

Version data entries

1 entries across 1 versions & 1 rubygems

Version Path
appswarm-0.0.1 lib/appswarm/routing/spec/nods_spec.rb