Module: WaitFor
- Defined in:
- lib/waitfor/version.rb,
lib/waitfor.rb,
lib/waitfor/waitfor_timeout_error.rb
Overview
:nodoc:
Defined Under Namespace
Modules: VERSION Classes: TimeoutError
Class Method Summary collapse
Class Method Details
.upto(options) ⇒ Object
9 10 11 12 13 14 |
# File 'lib/waitfor.rb', line 9 def upto( ) timer = Timer.new until yield or timer.out_of_time? sleep 1 end end |