function createChannelRequest() {
  xhrIo = new XhrIo();
  xhrIo.abort = xhrIo.abort || function() { this.active_ = false; };

  // Install mock browser channel and no-op debug logger.
  mockBrowserChannel = new MockBrowserChannel();
  /** @suppress {checkTypes} suppression added to enable type checking */
  channelRequest = new ChannelRequest(mockBrowserChannel, new ChannelDebug());

  // Install test XhrIo.
  /** @suppress {checkTypes} suppression added to enable type checking */
  mockBrowserChannel.createXhrIo = () => xhrIo;

  // Install watchdogTimeoutCallCount.
  /**
   * @suppress {strictMissingProperties} suppression added to enable type
   * checking
   */
  channelRequest.watchdogTimeoutCallCount = 0;
  /**
   * @suppress {strictMissingProperties,visibility} suppression added to enable
   * type checking
   */
  channelRequest.originalOnWatchDogTimeout = channelRequest.onWatchDogTimeout_;
  /**
   * @suppress {visibility,globalThis} suppression added to enable type
   * checking
   */
  channelRequest.onWatchDogTimeout_ = function() {
    this.watchdogTimeoutCallCount++;
    return this.originalOnWatchDogTimeout();
  };

  channelRequest.setTimeout(WATCHDOG_TIME);
}
Creates a real ChannelRequest object, with some modifications for
testability:
<ul>
<li>The BrowserChannel is a MockBrowserChannel.
<li>The new watchdogTimeoutCallCount property tracks onWatchDogTimeout()
    calls.
<li>The timeout is set to WATCHDOG_TIME.
</ul>