public void WithMsgHandlerRegistersGivenMessageHandler() { var connectionBuilder = new HubConnectionBuilder(); var msgHandler = Mock.Of <HttpMessageHandler>(); connectionBuilder.WithMessageHandler(msgHandler); Assert.Same(msgHandler, connectionBuilder.GetMessageHandler()); }