diff --git a/lib/puma/null_io.rb b/lib/puma/null_io.rb index 71d410c6..70f8fe38 100644 --- a/lib/puma/null_io.rb +++ b/lib/puma/null_io.rb @@ -52,5 +52,9 @@ module Puma def flush self end + + def closed? + true + end end end diff --git a/test/test_null_io.rb b/test/test_null_io.rb index 8a8f034b..c76183a1 100644 --- a/test/test_null_io.rb +++ b/test/test_null_io.rb @@ -64,4 +64,8 @@ class TestNullIO < Minitest::Test def test_flush_returns_self assert_equal nio, nio.flush end + + def test_closed_returns_true + assert_equal true, nio.closed? + end end