public void CreateModuleCatalogShouldInitializeModuleCatalog() { var bootstrapper = new DefaultBootstrapper(); bootstrapper.CallCreateModuleCatalog(); Assert.IsNotNull(bootstrapper.BaseModuleCatalog); }
public void CreateModuleCatalogShouldInitializeModuleCatalog() { var bootstrapper = new DefaultBootstrapper(); bootstrapper.CallCreateModuleCatalog(); Assert.IsNotNull(bootstrapper.BaseModuleCatalog); }
public void RegisterFrameworkExceptionTypesShouldRegisterActivationException() { var bootstrapper = new DefaultBootstrapper(); bootstrapper.CallRegisterFrameworkExceptionTypes(); Assert.IsTrue(ExceptionExtensions.IsFrameworkExceptionRegistered( typeof(Microsoft.Practices.ServiceLocation.ActivationException))); }
public void ConfigureDefaultRegionBehaviorsShouldAddRegionLifetimeBehavior() { var bootstrapper = new DefaultBootstrapper(); CreateAndConfigureServiceLocatorWithDefaultRegionBehaviors(); bootstrapper.CallConfigureDefaultRegionBehaviors(); Assert.IsTrue(bootstrapper.DefaultRegionBehaviorTypes.ContainsKey(RegionMemberLifetimeBehavior.BehaviorKey)); }
public void ConfigureDefaultRegionBehaviorsShouldAddSyncRegionContextWithHostBehavior() { var bootstrapper = new DefaultBootstrapper(); CreateAndConfigureServiceLocatorWithDefaultRegionBehaviors(); bootstrapper.CallConfigureDefaultRegionBehaviors(); Assert.IsTrue(bootstrapper.DefaultRegionBehaviorTypes.ContainsKey(SyncRegionContextWithHostBehavior.BehaviorKey)); }
public void ConfigureDefaultRegionBehaviorsShouldAddSixDefaultBehaviors() { var bootstrapper = new DefaultBootstrapper(); CreateAndConfigureServiceLocatorWithDefaultRegionBehaviors(); bootstrapper.CallConfigureDefaultRegionBehaviors(); Assert.AreEqual(6, bootstrapper.DefaultRegionBehaviorTypes.Count()); }
public void ConfigureDefaultRegionBehaviorsShouldBindRegionContextToDependencyObjectBehavior() { var bootstrapper = new DefaultBootstrapper(); CreateAndConfigureServiceLocatorWithDefaultRegionBehaviors(); bootstrapper.CallConfigureDefaultRegionBehaviors(); Assert.IsTrue(bootstrapper.DefaultRegionBehaviorTypes.ContainsKey(BindRegionContextToDependencyObjectBehavior.BehaviorKey)); }
public void ConfigureRegionAdapterMappingsShouldRegisterItemsControlMapping() { var bootstrapper = new DefaultBootstrapper(); CreateAndConfigureServiceLocatorWithRegionAdapters(); var regionAdapterMappings = bootstrapper.CallConfigureRegionAdapterMappings(); Assert.IsNotNull(regionAdapterMappings); Assert.IsNotNull(regionAdapterMappings.GetMapping(typeof(ItemsControl))); }
public void CreateLoggerInitializesLogger() { var bootstrapper = new DefaultBootstrapper(); bootstrapper.CallCreateLogger(); Assert.IsNotNull(bootstrapper.BaseLogger); #if SILVERLIGHT Assert.IsInstanceOfType(bootstrapper.BaseLogger, typeof(EmptyLogger)); #else Assert.IsInstanceOfType(bootstrapper.BaseLogger, typeof(TextLogger)); #endif }
public void CreateLoggerInitializesLogger() { var bootstrapper = new DefaultBootstrapper(); bootstrapper.CallCreateLogger(); Assert.IsNotNull(bootstrapper.BaseLogger); #if SILVERLIGHT Assert.IsInstanceOfType(bootstrapper.BaseLogger, typeof(EmptyLogger)); #else Assert.IsInstanceOfType(bootstrapper.BaseLogger, typeof(TextLogger)); #endif }
public void ShellDefaultsToNull() { var bootstrapper = new DefaultBootstrapper(); Assert.IsNull(bootstrapper.BaseShell); }
public void ModuleCatalogDefaultsToNull() { var bootstrapper = new DefaultBootstrapper(); Assert.IsNull(bootstrapper.BaseModuleCatalog); }
public void LoggerDefaultsToNull() { var bootstrapper = new DefaultBootstrapper(); Assert.IsNull(bootstrapper.BaseLogger); }
public void ConfigureDefaultRegionBehaviorsShouldAddRegionLifetimeBehavior() { var bootstrapper = new DefaultBootstrapper(); CreateAndConfigureServiceLocatorWithDefaultRegionBehaviors(); bootstrapper.CallConfigureDefaultRegionBehaviors(); Assert.IsTrue(bootstrapper.DefaultRegionBehaviorTypes.ContainsKey(RegionMemberLifetimeBehavior.BehaviorKey)); }
public void ConfigureDefaultRegionBehaviorsShouldAddSyncRegionContextWithHostBehavior() { var bootstrapper = new DefaultBootstrapper(); CreateAndConfigureServiceLocatorWithDefaultRegionBehaviors(); bootstrapper.CallConfigureDefaultRegionBehaviors(); Assert.IsTrue(bootstrapper.DefaultRegionBehaviorTypes.ContainsKey(SyncRegionContextWithHostBehavior.BehaviorKey)); }
public void ConfigureDefaultRegionBehaviorsShouldBindRegionContextToDependencyObjectBehavior() { var bootstrapper = new DefaultBootstrapper(); CreateAndConfigureServiceLocatorWithDefaultRegionBehaviors(); bootstrapper.CallConfigureDefaultRegionBehaviors(); Assert.IsTrue(bootstrapper.DefaultRegionBehaviorTypes.ContainsKey(BindRegionContextToDependencyObjectBehavior.BehaviorKey)); }
public void RegisterFrameworkExceptionTypesShouldRegisterActivationException() { var bootstrapper = new DefaultBootstrapper(); bootstrapper.CallRegisterFrameworkExceptionTypes(); Assert.IsTrue(ExceptionExtensions.IsFrameworkExceptionRegistered( typeof(Microsoft.Practices.ServiceLocation.ActivationException))); }
public void LoggerDefaultsToNull() { var bootstrapper = new DefaultBootstrapper(); Assert.IsNull(bootstrapper.BaseLogger); }
public void ModuleCatalogDefaultsToNull() { var bootstrapper = new DefaultBootstrapper(); Assert.IsNull(bootstrapper.BaseModuleCatalog); }
public void ShellDefaultsToNull() { var bootstrapper = new DefaultBootstrapper(); Assert.IsNull(bootstrapper.BaseShell); }
public void ConfigureRegionAdapterMappingsShouldRegisterItemsControlMapping() { var bootstrapper = new DefaultBootstrapper(); CreateAndConfigureServiceLocatorWithRegionAdapters(); var regionAdapterMappings = bootstrapper.CallConfigureRegionAdapterMappings(); Assert.IsNotNull(regionAdapterMappings); Assert.IsNotNull(regionAdapterMappings.GetMapping(typeof(ItemsControl))); }
public void ConfigureDefaultRegionBehaviorsShouldAddSevenDefaultBehaviors() { var bootstrapper = new DefaultBootstrapper(); CreateAndConfigureServiceLocatorWithDefaultRegionBehaviors(); bootstrapper.CallConfigureDefaultRegionBehaviors(); Assert.AreEqual(7, bootstrapper.DefaultRegionBehaviorTypes.Count()); }