Sha256: 7752a4e3b55489a0ec1d32cb71cc97829ee03d32914a5632328e1de7f9db22aa
Contents?: true
Size: 522 Bytes
Versions: 19
Compression:
Stored size: 522 Bytes
Contents
require 'spec/helper' describe Innate::DynaMap do @app = lambda{|env| [200, {}, ['pass']] } should 'raise if nothing is mapped' do lambda{ Innate::DynaMap.call({}) }.should.raise(RuntimeError) end should 'not raise if nothing is mapped' do Innate.map('/', &@app) Innate::DynaMap.call('SCRIPT_NAME' => '/').should == [200, {}, ['pass']] end should 'return mapped object' do Innate.at('/').should == @app end should 'return path to object' do Innate.to(@app).should == '/' end end
Version data entries
19 entries across 19 versions & 3 rubygems