public void SetUp()
        {
            var container = StructureMapContainerFacility.GetBasicFubuContainer();
            theHeaderValues = new KeyValues();

            theRequest = new RequestData();
            theRequest.AddValues(RequestDataSource.Header, theHeaderValues);

            container.Inject<IRequestData>(theRequest);

            theHeaders = container.GetInstance<RequestHeaders>();
        }
예제 #2
0
        public void SetUp()
        {
            theBinder = new StandardModelBinder(new BindingRegistry(), new TypeDescriptorCache());

            theRequestData = new RequestData();

            var otherDictionary = new Dictionary<string, string>();
            for (int i = 0; i < 10; i++)
            {
                otherDictionary.Add("Part" + i, Guid.NewGuid().ToString());
            }

            theRequestData.AddValues(RequestDataSource.Request, new DictionaryKeyValues(otherDictionary));

            theRouteValues = new Dictionary<string, string>();

            theRequestData.AddValues(RequestDataSource.Route.ToString(), new DictionaryKeyValues(theRouteValues));
        }