public void ReadPackages_ExceptionThrownWhenAccessingActiveRepository_ErrorMessageFromExceptionNotOverriddenByReadPackagesCall() { var registeredRepositories = new ExceptionThrowingRegisteredPackageRepositories(); registeredRepositories.ExeptionToThrowWhenRecentPackageRepositoryAccessed = new Exception("Test"); CreateViewModel(registeredRepositories); viewModel.ReadPackages(); ApplicationException ex = Assert.Throws <ApplicationException>(CompleteReadPackagesTask); Assert.AreEqual("Test", ex.Message); }
void CreateExceptionThrowingRegisteredPackageRepositories() { exceptionThrowingRegisteredPackageRepositories = new ExceptionThrowingRegisteredPackageRepositories(); }