Ejemplo n.º 1
0
        public void RegisterViewsServicesRegistersWatchListView()
        {
            var container = new MockUnityContainer();

            var module = new TestableWatchModule(container, new MockRegionManager());

            module.InvokeRegisterViewsAndServices();

            Assert.AreEqual(typeof(WatchListService), container.Types[typeof(IWatchListService)]);
            Assert.AreEqual(typeof(WatchListView), container.Types[typeof(IWatchListView)]);
            Assert.AreEqual(typeof(WatchListPresentationModel), container.Types[typeof(IWatchListPresentationModel)]);
            Assert.AreEqual(typeof(AddWatchView), container.Types[typeof(IAddWatchView)]);
            Assert.AreEqual(typeof(AddWatchPresenter), container.Types[typeof(IAddWatchPresenter)]);
        }
        public void RegisterViewsServicesRegistersWatchListView()
        {
            var container = new MockUnityContainer();

            var module = new TestableWatchModule(container, new MockRegionManager());

            module.InvokeRegisterViewsAndServices();

            Assert.AreEqual(typeof(WatchListService), container.Types[typeof(IWatchListService)]);
            Assert.AreEqual(typeof(WatchListView), container.Types[typeof(IWatchListView)]);
            Assert.AreEqual(typeof(WatchListPresentationModel), container.Types[typeof(IWatchListPresentationModel)]);
            Assert.AreEqual(typeof(AddWatchView), container.Types[typeof(IAddWatchView)]);
            Assert.AreEqual(typeof(AddWatchPresenter), container.Types[typeof(IAddWatchPresenter)]);
        }