Sha256: 1e89913636b27667297e799c2b9933ad94432dba788e2ae34328822105de53b0
Contents?: true
Size: 690 Bytes
Versions: 2
Compression:
Stored size: 690 Bytes
Contents
require 'spec_helper' require 'commute/core/util/path' describe Commute::Path do Path = Commute::Path describe 'with a single route' do it 'should walk the entire route' do path = Path.new([1,2,3].each) [path.succ, path.succ, path.succ].must_equal [1,2,3] end end describe 'with one detour' do it 'should walk the main route, the detour and the rest of the main route' do router = Path.new([1,2,3].each) router.succ.must_equal 1 router.succ.must_equal 2 router << ['a', 'b'].each router.succ.must_equal 'a' router.succ.must_equal 'b' router.succ.must_equal 3 router.succ.must_equal nil end end end
Version data entries
2 entries across 2 versions & 1 rubygems
Version | Path |
---|---|
commute-0.3.0.pre.2 | spec/commute/core/util/path_spec.rb |
commute-0.3.0.pre | spec/commute/core/util/path_spec.rb |