public UsersPreferencesHttpServiceV1Test()
        {
            _persistence = new UsersPreferencesMemoryPersistence();
            _controller  = new UsersPreferencesController();

            var config = ConfigParams.FromTuples(
                "connection.protocol", "http",
                "connection.host", "localhost",
                "connection.port", "3000"
                );

            _service = new UsersPreferencesHttpServiceV1();
            _service.Configure(config);

            var references = References.FromTuples(
                new Descriptor("pip-services-users-preferences", "persistence", "memory", "default", "1.0"), _persistence,
                new Descriptor("pip-services-users-preferences", "controller", "default", "default", "1.0"), _controller,
                new Descriptor("pip-services-users-preferences", "service", "http", "default", "1.0"), _service
                );

            _controller.SetReferences(references);

            _service.SetReferences(references);
            //_service.OpenAsync(null).Wait();

            // Todo: This is defect! Open shall not block the tread
            Task.Run(() => _service.OpenAsync(null));
            Thread.Sleep(1000); // Just let service a sec to be initialized
        }
        public UsersPreferencesDirectClientTest()
        {
            var persistence = new UsersPreferencesMemoryPersistence();
            var controller  = new UsersPreferencesController();

            References references = References.FromTuples(
                new Descriptor("pip-services-users-preferences", "persistence", "memory", "default", "1.0"), persistence,
                new Descriptor("pip-services-users-preferences", "controller", "default", "default", "1.0"), controller

                );

            controller.SetReferences(references);

            _client = new UsersPreferencesDirectClientV1();
            _client.SetReferences(references);

            //_fixture = new UsersPreferencesCilentFixture(_client);

            _client.OpenAsync(null);
        }