Sha256: 009988861d55ae3de9919dbf8d08b8af0804b1c8deaadec70c052a213daee74d

Contents?: true

Size: 525 Bytes

Versions: 2

Compression:

Stored size: 525 Bytes

Contents

require 'test/helper'

describe EventMachine::HttpRequest do

  def failed
    EventMachine.stop
    fail
  end

  it "should return and error if the response side exceeds the :max_bytes option" do
     EventMachine.run {
        http = EventMachine::HttpRequest.new("http://updates.sixapart.com/atom-stream.xml").get(:timeout => 10)
        http.errback { |http|
          http.errors.should match /Max Connection Duration Exceeded/
          EventMachine.stop
        }
        http.callback { failed }
      }
  end
  
end

Version data entries

2 entries across 2 versions & 1 rubygems

Version Path
astro-em-http-request-0.2.8 test/another_test.rb
astro-em-http-request-0.2.7 test/another_test.rb