From 59262122a84017e2c7861ce40ed97da3b415cd7d Mon Sep 17 00:00:00 2001 From: Pavel Krymets Date: Thu, 19 May 2016 14:57:19 -0700 Subject: [PATCH] Use UtcTime to fix tests --- test/Microsoft.AspNetCore.StaticFiles.Tests/CacheHeaderTests.cs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/test/Microsoft.AspNetCore.StaticFiles.Tests/CacheHeaderTests.cs b/test/Microsoft.AspNetCore.StaticFiles.Tests/CacheHeaderTests.cs index 6f9d8c9015..dc8d643330 100644 --- a/test/Microsoft.AspNetCore.StaticFiles.Tests/CacheHeaderTests.cs +++ b/test/Microsoft.AspNetCore.StaticFiles.Tests/CacheHeaderTests.cs @@ -340,7 +340,7 @@ namespace Microsoft.AspNetCore.StaticFiles { HttpResponseMessage res2 = await server .CreateRequest("/SubFolder/extra.xml") - .AddHeader("If-Modified-Since", DateTimeOffset.Now.ToString(format)) + .AddHeader("If-Modified-Since", DateTimeOffset.UtcNow.ToString(format)) .SendAsync(method.Method); Assert.Equal(HttpStatusCode.NotModified, res2.StatusCode);