public void FixtureSetup() { _indexRebuilderMock = new IndexRebuilderMock(); var builder = new ContainerBuilder(); builder.Register(c => _searchBLFactory()).As<ISearchBL>().RequestScoped(); builder.Register(c => _pageBLFactory()).As<IPageBL>().RequestScoped(); builder.Register(_indexRebuilderMock).As<IIndexRebuilder>(); _hostInfo = DreamTestHelper.CreateRandomPortHost(new XDoc("config").Elem("apikey", Utils.Settings.ApiKey), builder.Build()); _hostInfo.Host.Self.At("load").With("name", "mindtouch.deki").Post(DreamMessage.Ok()); _hostInfo.Host.Self.At("load").With("name", "mindtouch.deki.services").Post(DreamMessage.Ok()); _hostInfo.Host.Self.At("load").With("name", "mindtouch.indexservice").Post(DreamMessage.Ok()); _deki = DreamTestHelper.CreateService(_hostInfo, Utils.Settings.DekiConfig); _search = _deki.AtLocalHost.At("site", "query"); }
public void FixtureSetup() { _indexRebuilderMock = new IndexRebuilderMock(); var builder = new ContainerBuilder(); builder.Register(c => _searchBLFactory()).As <ISearchBL>().RequestScoped(); builder.Register(c => _pageBLFactory()).As <IPageBL>().RequestScoped(); builder.Register(_indexRebuilderMock).As <IIndexRebuilder>(); _hostInfo = DreamTestHelper.CreateRandomPortHost(new XDoc("config").Elem("apikey", Utils.Settings.ApiKey), builder.Build()); _hostInfo.Host.Self.At("load").With("name", "mindtouch.deki").Post(DreamMessage.Ok()); _hostInfo.Host.Self.At("load").With("name", "mindtouch.deki.services").Post(DreamMessage.Ok()); _hostInfo.Host.Self.At("load").With("name", "mindtouch.indexservice").Post(DreamMessage.Ok()); _deki = DreamTestHelper.CreateService(_hostInfo, Utils.Settings.DekiConfig); _search = _deki.AtLocalHost.At("site", "query"); }