channelrequest_test.js
No description.

File Location

/goog/net/channelrequest_test.js

Classes

MockBrowserChannel
Constructs a duck-type BrowserChannel that tracks the completed requests.

Public Protected Private

Enumerations

Global Functions

checkReachabilityEvents()
No description.
code »
createChannelRequest()
Creates a real ChannelRequest object, with some modifications for testability:
  • The BrowserChannel is a MockBrowserChannel.
  • The new watchdogTimeoutCallCount property tracks onWatchDogTimeout_() calls.
  • The timeout is set to WATCHDOG_TIME.
code »
mockBrowserChannel.createXhrIo()
No description.
code »
setUp()
No description.
code »
tearDown()
No description.
code »
testActiveXBlocked()
No description.
code »
testNetworkEvents()
Run through the lifecycle of a long lived request, checking that the right network events are reported.
code »
testNetworkEvents_throttleReadyStateChange()
Test throttling of readystatechange events.
code »
testRequestTimeout()
Make sure that the request "completes" with an error when the timeout expires.
code »
testRequestTimeoutWithUnexpectedException()
No description.
code »

Global Variables

THROTTLE_TIME :
Time to throttle readystatechange events.
Code »
WATCHDOG_TIME :
Time to wait for a network request to time out, before aborting.
Code »
abort :
No description.
Code »
No description.
Code »
mockBrowserChannel : MockBrowserChannel
No description.
Code »

Directory net

File Reference