about summary refs log tree commit homepage
diff options
context:
space:
mode:
authorEric Wong <normalperson@yhbt.net>2013-05-03 01:18:43 +0000
committerEric Wong <normalperson@yhbt.net>2013-05-03 01:18:43 +0000
commit565b92da156ddf268634c3e1076d51d811ff0dc6 (patch)
treedf20274337cb060fa21d4bf33cfd6a4db3082bcd
parent33985d31bd01b32f6264ec7d87f40dcbb0c924be (diff)
downloadsleepy_penguin-565b92da156ddf268634c3e1076d51d811ff0dc6.tar.gz
We need to ensure Kqueue::IO remains IO-like
-rw-r--r--test/test_kqueue_io.rb7
1 files changed, 7 insertions, 0 deletions
diff --git a/test/test_kqueue_io.rb b/test/test_kqueue_io.rb
index 076c9f0..04e3103 100644
--- a/test/test_kqueue_io.rb
+++ b/test/test_kqueue_io.rb
@@ -16,6 +16,13 @@ class TestKqueueIO < Test::Unit::TestCase
     end
   end
 
+  def test_io_like
+    kq = Kqueue::IO.new
+    @to_close << kq
+    assert_equal kq, kq.to_io
+    assert_kind_of Integer, kq.fileno
+  end
+
   def test_bad_type
     kq = Kqueue::IO.new
     @to_close << kq