Пример #1
0
        public Http2HttpProtocolFeatureCollectionTests()
        {
            var context = TestContextFactory.CreateHttp2StreamContext(
                serviceContext: new TestServiceContext(),
                timeoutControl: Mock.Of <ITimeoutControl>());

            var http2Stream = new TestHttp2Stream(context);

            http2Stream.Reset();
            _http2Collection = http2Stream;
        }
Пример #2
0
        public HttpProtocolFeatureCollectionTests()
        {
            var context = new Http2StreamContext
            {
                ServiceContext     = new TestServiceContext(),
                ConnectionFeatures = new FeatureCollection(),
                TimeoutControl     = Mock.Of <ITimeoutControl>(),
                Transport          = Mock.Of <IDuplexPipe>(),
                ServerPeerSettings = new Http2PeerSettings(),
                ClientPeerSettings = new Http2PeerSettings(),
            };

            _httpConnectionContext = context;
            _http1Connection       = new TestHttp1Connection(context);
            _http1Connection.Reset();
            _collection = _http1Connection;

            var http2Stream = new TestHttp2Stream(context);

            http2Stream.Reset();
            _http2Collection = http2Stream;
        }