public void UseInterceptor_WithNull_ShouldThrowException() { var sut = new ModelValidatorFluentBuilder(); Should.Throw<ArgumentNullException>(() => { var chain = sut.UseInterceptor(null); }); }
public void UseInterceptor_With_ShouldNotBeNull() { var sut = new ModelValidatorFluentBuilder(); var interceptor = new Mock<IModelValidatorInterceptor>(); var chain = sut.UseInterceptor(interceptor.Object); chain.ShouldNotBeNull(); sut.ModelValidatorInterceptor.ShouldNotBeNull(); chain.ShouldBeAssignableTo<IModelValidatorEndFluentBuilder>(); }