Web Application UI Test Automation with the WebBrowser Control

A common type of software testing is verifying the functionality of a Web application through its user interface. For complex user scenarios, a manual testing approach is usually best but for simple user scenarios it often makes sense to write test automation. There are many ways to automate Web app UI testing. One technique is to leverage the WebBrowser control. The WebBrowser control essentially allows you to embed a Web browser into a WinForm application and gives you the ability to programmatically manipulate the Web app under test. See the image below. One advantage of this approach is that the WinfForm test harness can also deal with popup boxes – something difficult to do with other testing approaches. One disadvantage of the WebBrowser control approach is that the technique effectively targets only Internet Explorer. I describe exactly how to create Web app UI test automation in the November 2010 issue of MSDN Magazine at http://msdn.microsoft.com/en-us/magazine/gg309183.aspx.

This entry was posted in Software Test Automation. Bookmark the permalink.