public void IsProxyCheckerInstalled_GeneralExceptionNotCaught() { //Arrange SetupInGac(); var target = new TestableApplicationContextProvider(true); MSPUtility.ExecuteRegisteredProxyOperationStringStringSPProxyOperationArgs = (a, t, args) => { throw new LoggingException(); }; bool expectedExceptionThrown = false; //Act try { bool result = target.IsProxyCheckerInstalled(); } catch (LoggingException) { expectedExceptionThrown = true; } //Assert Assert.IsTrue(expectedExceptionThrown); }
public void IsProxyCheckerInstalled_ReturnsTrueWhenInGac() { //Arrange SetupInGac(); var target = new TestableApplicationContextProvider(true); //Act bool result = target.IsProxyCheckerInstalled(); //Assert Assert.IsTrue(result); }