I've gotten a simple WatiN web test running on my dev environment and am trying to get it working on the TFS build server.
It is failing when just trying to load a page with the following exception:
WatiN.Core.Exceptions.TimeoutException: Timeout while Internet Explorer busy.
I've set the test timeout to 3 minutes which should be plenty.
I've read that this could be caused by IE protected mode, but I'm not sure how to disable that for the TFSService account.
I'm using Visual Studio/TFS 2008 on Windows Server 2008.
Has anyone else hit this problem and found a solution?
I've only used WatiN on Vista, which had a similar timeout problem. I was much happier when I switched to FireFox for my tests.
Anyway, here is a possible solution:
http://msdn.microsoft.com/en-us/magazine/dd744751.aspx
The ASP.NET Development Server only
listens for requests on IPv4, not
IPv6. If you are running Windows Vista
or Windows Server 2008, requests for
"localhost" will resolve to the IPv6
address of ::1 by default rather than
the IPv4 address of 127.0.0.1 and the
WatiN tests will fail. To resolve this
issue, comment out the IPv6 localhost
address in your
C:\Windows\System32\drivers\etc\hosts
file. This is the line with "::1
localhost".
I found the solution to this - it was to turn off "IE Enhanced Security Configuration" for Administrators.
Next problem is that WatiN thinks it is not running in a STA thread - I'll post a separate question on that.