From 3852a7793a151b13426eac968ebe06efc297658f Mon Sep 17 00:00:00 2001 From: Viktor Hofer Date: Wed, 9 Jun 2021 17:46:44 +0200 Subject: [PATCH] Fix failing SetCookies_Success test (#53932) * Fix failing SetCookies_Success test --- .../tests/UnitTests/CookieContainerTest.cs | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/src/libraries/System.Net.Primitives/tests/UnitTests/CookieContainerTest.cs b/src/libraries/System.Net.Primitives/tests/UnitTests/CookieContainerTest.cs index 442c3495c94..b3673331aeb 100644 --- a/src/libraries/System.Net.Primitives/tests/UnitTests/CookieContainerTest.cs +++ b/src/libraries/System.Net.Primitives/tests/UnitTests/CookieContainerTest.cs @@ -125,11 +125,11 @@ public static IEnumerable SetCookiesData() yield return new object[] { u, - "name98=value98; path=/; domain=.uri.com; expires=Wed, 09 Jun 2021 10:18:14 GMT, name99=value99", + "name98=value98; path=/; domain=.uri.com; expires=Wed, 09 Jun 2050 10:18:14 GMT, name99=value99", new Cookie[] { new Cookie("name99", "value99"), - new Cookie("name98", "value98", "/", ".uri.com") { Expires = new DateTime(2021, 6, 9, 10, 18, 14) } + new Cookie("name98", "value98", "/", ".uri.com") { Expires = new DateTime(2050, 6, 9, 10, 18, 14) } } }; // Version0 @@ -169,11 +169,11 @@ public static IEnumerable SetCookiesData() yield return new object[] { uSecure, - "name98=value98; name98=value98; comment=comment; comment=comment2; commentURL=http://url.com; commentURL=commentURL2; discard; discard; domain=.uri.com; domain=domain2; max-age=400; max-age=400; path=/; path=path; port=\"80, 90, 443\"; port=port2; path=path; expires=Wed, 09 Jun 2021 10:18:14 GMT; expires=expires2; secure; secure; httponly; httponly; Version=100; Version=100, name99=value99", + "name98=value98; name98=value98; comment=comment; comment=comment2; commentURL=http://url.com; commentURL=commentURL2; discard; discard; domain=.uri.com; domain=domain2; max-age=400; max-age=400; path=/; path=path; port=\"80, 90, 443\"; port=port2; path=path; expires=Wed, 09 Jun 2050 10:18:14 GMT; expires=expires2; secure; secure; httponly; httponly; Version=100; Version=100, name99=value99", new Cookie[] { new Cookie("name99", "value99"), - new Cookie("name98", "value98", "/", ".uri.com") { Port = "\"80, 90, 443\"", Version = 100, Secure = true, HttpOnly = true, Discard = true, Expires = new DateTime(2021, 6, 9, 10, 18, 14), Comment = "comment", CommentUri = new Uri("http://url.com") } + new Cookie("name98", "value98", "/", ".uri.com") { Port = "\"80, 90, 443\"", Version = 100, Secure = true, HttpOnly = true, Discard = true, Expires = new DateTime(2050, 6, 9, 10, 18, 14), Comment = "comment", CommentUri = new Uri("http://url.com") } } }; // Double entries -- GitLab