Example #1
0
        public void Setup()
        {
            var pocoConfiguration = new PocoConfiguration()
            {
                Handler        = new DummyServer(),
                ResponseReader = (a, b, c) => Task.Factory.StartNew(() =>
                {
                    _requestUri =
                        a.RequestMessage.RequestUri;
                    return((object)new Car[0]);
                })
            };

            pocoConfiguration.Handler = new DummyServer();
            _pocoClient = new PocoClient(pocoConfiguration)
            {
                BaseAddress = new Uri("http://non-existent-server/api/")
            };
        }
Example #2
0
		public void Setup()
		{
			var pocoConfiguration = new PocoConfiguration()
			                        	{
				Handler = new DummyServer(),
				ResponseReader = (a, b, c) => Task.Factory.StartNew(() =>
			                        		{
			                        			_requestUri =
			                        				a.RequestMessage.RequestUri;
			                        			return (object) new Car[0];
			                        		})
											
			                        	};

			pocoConfiguration.Handler = new DummyServer();
			_pocoClient = new PocoClient(pocoConfiguration)
			              	{
			              		BaseAddress = new Uri("http://non-existent-server/api/")
			              	};


		}