public void HeadersTest_Should_Not_Send_File_If_File_Has_Not_Been_Changed() { Request.Headers[HttpHeaders.IfNoneMatch] = ResumeFileResult.Util.Etag(_file); var result = new MockResumeFileResult(_file.FullName, ContentType, Request); Assert.IsTrue(result.IsNotModified()); result.WriteFileTest(Response); Assert.AreEqual((int)HttpStatusCode.NotModified, Response.StatusCode); Assert.IsNotNull(Response.Headers[HttpHeaders.Etag]); Assert.IsNotNull(Response.Headers[HttpHeaders.Expires]); Assert.IsNotNull(Response.Headers[HttpHeaders.LastModified]); Assert.IsNull(Response.Headers[HttpHeaders.ContentRange]); Assert.AreEqual(0, Response.OutputStream.Length); }