Sha256: 2b85403797a7198958dd3150e3c0a9821c0de8a225149e4025c8a6a20f729a95

Contents?: true

Size: 459 Bytes

Versions: 2

Compression:

Stored size: 459 Bytes

Contents

#
# Testing rufus-verbs
#
# jmettraux@gmail.com
#
# Mon May 26 17:04:25 JST 2008
#

require File.dirname(__FILE__) + '/base.rb'


class TimeoutTest < Test::Unit::TestCase
  include TestBaseMixin

  include Rufus::Verbs


  def test_0

    error = nil
    t = Time.now

    begin
      get :uri => "http://localhost:7777/lost", :to => 1
    rescue Timeout::Error => e
      error = e
    end

    assert_not_nil error
    assert (Time.now - t < 2)
  end
end

Version data entries

2 entries across 2 versions & 1 rubygems

Version Path
rufus-verbs-1.0.1 test/timeout_test.rb
rufus-verbs-1.0.0 test/timeout_test.rb