コード例 #1
0
        public virtual void Setup()
        {
            Unit = new HttpContextPolicyProvider();

            _requestHeaders  = new NameValueCollection();
            _responseHeaders = new NameValueCollection();

            HttpContextManager.SetCurrentContext(GetMockedHttpContext());
        }
コード例 #2
0
        public override void Setup()
        {
            Unit = new HttpContextPolicyProvider(new List <IHttpContextPolicy>()
            {
                new ResponseHeaderRestrictedCachePolicy()
            });

            _requestHeaders  = new NameValueCollection();
            _responseHeaders = new NameValueCollection();

            HttpContextManager.SetCurrentContext(GetMockedHttpContext());
        }