diff options
author | Lars Gierth <lars.gierth@gmail.com> | 2011-12-28 01:59:40 +0100 |
---|---|---|
committer | Lars Gierth <lars@soundcloud.com> | 2012-03-31 20:23:55 +0200 |
commit | 0cb39b04c578ce3a510635b4a169379a1e0d5fd5 (patch) | |
tree | daaf0df491d118111982970443403a8cfb843d64 /test/spec_directory.rb | |
parent | bd43405d79dfc3c750e64fc16a0398ca6c07850a (diff) | |
download | rack-0cb39b04c578ce3a510635b4a169379a1e0d5fd5.tar.gz |
Wrap test apps in Rack::Lint and fix uncovered errors (third pass)
Update tests for Directory, ETag, File and Head.
Diffstat (limited to 'test/spec_directory.rb')
-rw-r--r-- | test/spec_directory.rb | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/test/spec_directory.rb b/test/spec_directory.rb index 81b8c55b..d017975a 100644 --- a/test/spec_directory.rb +++ b/test/spec_directory.rb @@ -1,10 +1,11 @@ require 'rack/directory' +require 'rack/lint' require 'rack/mock' describe Rack::Directory do DOCROOT = File.expand_path(File.dirname(__FILE__)) unless defined? DOCROOT FILE_CATCH = proc{|env| [200, {'Content-Type'=>'text/plain', "Content-Length" => "7"}, ['passed!']] } - app = Rack::Directory.new DOCROOT, FILE_CATCH + app = Rack::Lint.new(Rack::Directory.new(DOCROOT, FILE_CATCH)) should "serve directory indices" do res = Rack::MockRequest.new(Rack::Lint.new(app)). |