public void WithContainer_WhenInvoked_ShouldSetTheContainer() { //Arrange var container = A.Fake <IUnityContainer>(); var containerOptions = A.Fake <IBootstrapperContainerExtensionOptions>(); var options = new UnityOptions(containerOptions); //Act options.WithContainer(container); //Assert Assert.AreSame(container, options.Container); }
public void WithContainer_WhenInvoked_ShouldReturnTheSameUnityOptions() { //Arrange var container = A.Fake <IUnityContainer>(); var containerOptions = A.Fake <IBootstrapperContainerExtensionOptions>(); var options = new UnityOptions(containerOptions); //Act var result = options.WithContainer(container); //Assert Assert.AreSame(options, result); }