OpenQA.Selenium.CookieImplementationTest.ShouldNotShowCookieAddedToDifferentPath C# (CSharp) Method

ShouldNotShowCookieAddedToDifferentPath() private method

private ShouldNotShowCookieAddedToDifferentPath ( ) : void
return void
        public void ShouldNotShowCookieAddedToDifferentPath()
        {
            driver.Url = macbethPage;
            IOptions options = driver.Manage();
            Cookie cookie = new Cookie("Lisa", "Simpson", EnvironmentManager.Instance.UrlBuilder.HostName, "/" + EnvironmentManager.Instance.UrlBuilder.Path + "IDoNotExist", null);
            options.AddCookie(cookie);
            ReadOnlyCollection<Cookie> cookies = options.GetCookies();
            Assert.IsFalse(cookies.Contains(cookie), "Invalid cookie was returned");
        }