开发者

WatiN clear browser cache

开发者 https://www.devze.com 2022-12-08 03:00 出处:网络
It seems the ClearCache method doesn\'t quite work for IE in WatiN. at least, it doesn\'t work for things you\'ve cached SINCE yo开发者_JAVA百科u\'ve opened the instance.

It seems the ClearCache method doesn't quite work for IE in WatiN. at least, it doesn't work for things you've cached SINCE yo开发者_JAVA百科u've opened the instance.

Any suggestions?

I tried using ReOpen, but it errors. It also seems to do the same thing as

Browser.Close();
Browser = new IE();

Which is slow. My tests take just about twice as long to run doing it that way (which is the only current workaround for clearing the cache).

Thanks in advance.


Go through this url this will help you.

http://jawedm.blogspot.com/2009/08/working-with-cookies-and-caches-using.html

using(IE ie = new IE())
{
ie.ClearCache();
ie.ClearCookies();

}
0

精彩评论

暂无评论...
验证码 换一张
取 消