Show
Ignore:
Timestamp:
09/16/08 03:33:27 (10 months ago)
Author:
francis
Message:

supported optional version string in HTTP client.

Files:

Legend:

Unmodified
Added
Removed
Modified
Copied
Moved
  • trunk/tests/test_httpclient.rb

    r668 r786  
    112112      assert ok 
    113113  end 
     114 
    114115 
    115116  #--------------------------------------- 
     
    190191  end 
    191192 
     193 
     194 
     195  # We can tell the client to send an HTTP/1.0 request (default is 1.1). 
     196  # This is useful for suppressing chunked responses until those are working. 
     197  def test_version_1_0 
     198    ok = false 
     199    EM.run { 
     200      c = EM::P::HttpClient.request :host => "www.bayshorenetworks.com", 
     201        :port => 80, 
     202        :version => "1.0" 
     203      c.callback {|result| 
     204        ok = true; 
     205        EventMachine.stop 
     206      } 
     207      c.errback {EventMachine.stop} 
     208    } 
     209    assert ok 
     210  end 
     211 
     212 
    192213end 
    193214