public InMemoryHttpServer(string baseUrl, IRepository<User> repository, IEnumerable<Route> routes)
        {
            this.routes = routes;
            this.baseUrl = baseUrl;
            var config = new HttpConfiguration();
            this.AddHttpRoutes(config.Routes);
            config.IncludeErrorDetailPolicy = IncludeErrorDetailPolicy.Always;


            var resolver = new TestPlacesDependencyResolver();
            resolver.UsersRepository = repository;
            config.DependencyResolver = resolver;

            var server = new HttpServer(config);
            this.client = new HttpClient(server);
        }
        public InMemoryHttpServer(string baseUrl, IRepository <User> repository, IEnumerable <Route> routes)
        {
            this.routes  = routes;
            this.baseUrl = baseUrl;
            var config = new HttpConfiguration();

            this.AddHttpRoutes(config.Routes);
            config.IncludeErrorDetailPolicy = IncludeErrorDetailPolicy.Always;


            var resolver = new TestPlacesDependencyResolver();

            resolver.UsersRepository  = repository;
            config.DependencyResolver = resolver;

            var server = new HttpServer(config);

            this.client = new HttpClient(server);
        }