public void Should_Set_Cookie() { var cookie = new Cookie("uweb", "uweb"); response.AddCookie(cookie); response.Cookies.ShouldHaveCount(1); Assert.AreSame(cookie, response.Cookies.First()); }
public void AppendCookie_Adds_Cookie_To_Response() { var cookie = new Cookie("uweb", "uweb"); outputWriter.AppendCookie(cookie); var response = outputWriter.CreateResponse(); response.Cookies.ShouldHaveCount(1); Assert.Same(cookie, response.Cookies.First()); }
public void Should_Create_Cookie_With_Name_Value_HttpOnly_And_Secure() { var cookie = new Cookie("uweb", "uweb", true, true); ValidateCookie(cookie, "uweb", "uweb", true, true); }
public void Should_Create_Cookie_With_Name_And_Value() { var cookie = new Cookie("uweb", "uweb"); ValidateCookie(cookie, "uweb", "uweb", false, false); }