Is there any way to delete an HttpOnly cookie from C# Selenium tests?

Posted by BenA on Stack Overflow See other posts from Stack Overflow or by BenA
Published on 2010-05-25T14:58:52Z Indexed on 2010/05/25 15:01 UTC
Read the original article Hit count: 293

I have a set of C# Selenium tests that need to delete a cookie that has the HttpOnly flag set.

Unfortunately the DefaultSelenium.GetCookie() and DefaultSelenium.DeleteCookie() commands aren't able to access the cookie, because it has that HttpOnly flag set. I've confirmed this by removing the flag by hand, and checking that subsequent calls to either of those methods are then happily able to manipulate the cookie in question.

Is there any other way to do this via the Selenium .NET client driver?

All ideas welcome!

© Stack Overflow or respective owner

Related posts about c#

Related posts about cookies