Example #1
0
 public void GivenContextWithNon404Response_ReturnsFalse()
 {
     _nancyContext.Response.StatusCode = HttpStatusCode.OK;
     PassThroughDecider.ConfigureAndPerformPassThroughIfNeeded(_nancyContext).Should().BeFalse();
 }
Example #2
0
 public void GivenContextWithoutResponse_ReturnsFalse()
 {
     _nancyContext.Response = null;
     PassThroughDecider.ConfigureAndPerformPassThroughIfNeeded(_nancyContext).Should().BeFalse();
 }
Example #3
0
 public void GivenContextWith404Response_ReturnsTrue()
 {
     _nancyContext.Response.StatusCode = HttpStatusCode.NotFound;
     PassThroughDecider.ConfigureAndPerformPassThroughIfNeeded(_nancyContext).Should().BeTrue();
 }
Example #4
0
 public void GivenNullContext_ReturnsFalse()
 {
     PassThroughDecider.ConfigureAndPerformPassThroughIfNeeded(null).Should().BeFalse();
 }