diff options
Diffstat (limited to 'test/test_clogger.rb')
-rw-r--r-- | test/test_clogger.rb | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/test/test_clogger.rb b/test/test_clogger.rb index 4dc1371..8e6604e 100644 --- a/test/test_clogger.rb +++ b/test/test_clogger.rb @@ -426,4 +426,12 @@ class TestClogger < Test::Unit::TestCase assert_equal "5\n", str.string end + def test_http_content_type_fallback + str = StringIO.new + app = lambda { |env| [302, [ %w(a) ], []] } + cl = Clogger.new(app, :logger => str, :format => '$http_content_type') + cl.call(@req.merge('CONTENT_TYPE' => 'text/plain')) + assert_equal "text/plain\n", str.string + end + end |