Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Browse files

fix idle test with epoll (cc #427)

  • Loading branch information...
commit 61095b48790ff63ea6aebf751c282332016f7a53 1 parent 7f5e231
@tmm1 tmm1 authored
Showing with 6 additions and 4 deletions.
  1. +6 −4 tests/test_idle_connection.rb
View
10 tests/test_idle_connection.rb
@@ -9,15 +9,17 @@ def test_idle_time
$idle_time = conn.get_idle_time
conn.send_data "GET / HTTP/1.0\r\n\r\n"
EM.next_tick{
- $idle_time_after_send = conn.get_idle_time
- conn.close_connection
- EM.stop
+ EM.next_tick{
+ $idle_time_after_send = conn.get_idle_time
+ conn.close_connection
+ EM.stop
+ }
}
}
}
assert_in_delta 3, $idle_time, 0.2
- assert_equal 0, $idle_time_after_send
+ assert_in_delta 0, $idle_time_after_send, 0.1
end
end
end
Please sign in to comment.
Something went wrong with that request. Please try again.