summary refs log tree commit homepage
path: root/t
diff options
context:
space:
mode:
authorEric Wong <normalperson@yhbt.net>2011-01-14 18:49:58 +0000
committerEric Wong <normalperson@yhbt.net>2011-01-14 20:33:37 +0000
commit18db44fe89b8ba61f21b92f6efece37baa8bd6c7 (patch)
treeaac0be37b373f23d7059739156aff9bb7025e7b9 /t
parent2eb58a62a5e738c287db8239f4f4e8d1d02ed328 (diff)
We always try to track the latest and greatest.  We've also
updated the test to actually test concurrency since
rack-fiber_pool reuses recent fibers now.
Diffstat (limited to 't')
-rw-r--r--t/rack-fiber_pool/app.ru7
-rw-r--r--t/test_isolate.rb2
2 files changed, 7 insertions, 2 deletions
diff --git a/t/rack-fiber_pool/app.ru b/t/rack-fiber_pool/app.ru
index a4777ca..e4f60a4 100644
--- a/t/rack-fiber_pool/app.ru
+++ b/t/rack-fiber_pool/app.ru
@@ -2,4 +2,9 @@ require 'rack/fiber_pool'
 use Rack::FiberPool
 use Rack::ContentLength
 use Rack::ContentType, 'text/plain'
-run lambda { |env| [ 200, {}, [ "#{Fiber.current}\n" ] ] }
+run lambda { |env|
+  f = Fiber.current
+  EM.add_timer(3) { f.resume }
+  Fiber.yield
+  [ 200, {}, [ "#{f}\n" ] ]
+}
diff --git a/t/test_isolate.rb b/t/test_isolate.rb
index 0ab80f9..9b0c026 100644
--- a/t/test_isolate.rb
+++ b/t/test_isolate.rb
@@ -31,7 +31,7 @@ Isolate.now!(opts) do
 
   if defined?(::Fiber) && engine == "ruby"
     gem 'revactor', '0.1.5'
-    gem 'rack-fiber_pool', '0.9.0'
+    gem 'rack-fiber_pool', '0.9.1'
   end
 end