spec/innate/route.rb in manveru-innate-2009.02.25 vs spec/innate/route.rb in manveru-innate-2009.03.24

- old
+ new

@@ -1,11 +1,9 @@ require 'spec/helper' class SpecRouter - include Innate::Node - map '/' - provide :html => :None + Innate.node('/').provide(:html, :None) def float(flt) "Float: %3.3f" % flt end @@ -124,10 +122,10 @@ it 'should exclude existing actions' do got = Innate::Mock.get('/bar') got.status.should == 200 got.body.should == 'this is bar' end - + it 'should rewite with (key, val)' do Innate::Rewrite[ %r!^/(.+)$! ] = nil Innate::Rewrite(%r!^/(.+)$!, "/string/%s") got = Innate::Mock.get('/hello') got.status.should == 200