Sha256: 3357a82b3533b27091e04f22172a0d40cee32e3abbe0b9c99474f027823cf1ec
Contents?: true
Size: 618 Bytes
Versions: 12
Compression:
Stored size: 618 Bytes
Contents
require 'spec_helper' require 'rack/test' require 'tdiary/rack/static' describe TDiary::Rack::Static do include Rack::Test::Methods describe "reserve static files" do let(:app) { TDiary::Rack::Static.new( lambda{|env| [500, {}, ['Internal Server Error']]}, 'doc')} it 'should return the file in static directory' do get '/README.md' last_response.should be_ok end it 'should run the app if file is not exist' do get '/index.rb' last_response.status.should be 500 end it 'should run the app when post method' do post '/index.rb' last_response.status.should be 500 end end end
Version data entries
12 entries across 12 versions & 1 rubygems