public void CanHandle_should_return_true_if_exception_can_be_handled() { var sut = new ExceptionFilters(new[] { new ExceptionFilter(ex => ex is ArgumentNullException) }); var ex = new ArgumentNullException(); sut.CanHandle(ex).Should().BeTrue(); }
public void CanHandle_should_return_false_if_exception_cannot_be_handled() { var sut = new ExceptionFilters(new[] { new ExceptionFilter(ex => ex is ArgumentNullException) }); var ex = new ApplicationException(); sut.CanHandle(ex).Should().BeFalse(); }