about summary refs log tree commit homepage
path: root/test/test_posix_mq.rb
diff options
context:
space:
mode:
Diffstat (limited to 'test/test_posix_mq.rb')
-rw-r--r--test/test_posix_mq.rb6
1 files changed, 6 insertions, 0 deletions
diff --git a/test/test_posix_mq.rb b/test/test_posix_mq.rb
index 1fa029b..33bb2a0 100644
--- a/test/test_posix_mq.rb
+++ b/test/test_posix_mq.rb
@@ -90,6 +90,12 @@ class Test_POSIX_MQ < Test::Unit::TestCase
     assert_equal [ "world", 0 ], @mq.receive
   end
 
+  def test_shift
+    @mq = POSIX_MQ.new @path, IO::CREAT|IO::RDWR, 0666
+    @mq << "hello"
+    assert_equal "hello", @mq.shift
+  end
+
   def test_send_receive
     @mq = POSIX_MQ.new @path, IO::CREAT|IO::RDWR, 0666
     assert_nil @mq.send("hello", 0)