Caves Travel Diving Graphics Mizar Texts Cuisine Lemkov Contact Map RSS Polski
Trybiks' Dive Texts Testing Automated GUI Testing in VMs YAC Software












Rhino Mocks



UI Testing




Automated GUI Testing in VMs
I'm a big fan of automated testing (probably mostly because of being forced to test manually what could've been easily automated - but, well, programmers in Poland seem to be too cheap for US corporations - but that's another story). And I mean automated testing of every aspect of an application - backend code, business logic, DB access, networking, and especially GUI (I really don't get those articles about GUIs being difficult to test - but that's again another story).

Anyway, one of the problems of GUI testing is that you need to simulate key and mouse clicks. But then you end up with a "locked" computer - while these operations are going on, you can't do anything in other programs, since your actions on the keyboard or with the mouse may mess up the tests behavior. Instead of simulating user actions, you start generating these actions.

This isn't a problem when your tests take several minutes - always a good time to have some more coffee. :-) But when tests start to take longer and longer, it becomes a real problem.

Well, I accidentally found a perfect solution while investigating virtual machines. I was creating a standard "development" VM with all dev tools installed and configured. I'm using Sun's VirtualBox (even when writing this text), and even though it has some quirks, it works nicely as a GUI testing tool!

Namely, just open a VM session, start your tests, move to another application (outside of this VM) and... you can continue work while all keyboard and mouse events take place in that VM. You can even monitor what's happening in the VM when having it open on another monitor.

I really recommend such a setup, unless, of course, you're running your tests on a different machine entirely. Then, I guess, a VM isn't really needed for testing... :-)


No comments yet...


Add a comment (fields with an asterisk are required)
Name / nick *
Mail (will remain hidden) *
Your website
Comment (no tags) *
Enter the text displayed below *




UI Testing

Related pages

AssertWasCalled and Methods Called Multiple Times

AssertWas[Not]Called and Object Properties

Rhino Mocks's AssertWasNotCalled

Visual Studio - moving coded UI tests to a new / different project results in null reference exceptions

PrivateObject and Out/ByRef parameters

PrivateObject, WithEvents, and generics

Accessing private members of base classes

PrivateObject and WithEvents

Accessing private and protected members - PrivateObject and PrivateType

VS - Test Run Error - "COM object that has been separated from its underlying RCW cannot be used"

Get the TreeViewItem for an Item in a WPF TreeView

Output in MSTest Tests (VS 2010)

Automated WPF tests and "Invalid URI: Invalid port specified."

Checking Property Change Notifications

Checking "Dangling" Event Handlers in Delphi Forms

Rhino Mocks's AssertWasCalled in VB.NET

First steps with Rhino Mocks (in VB.NET)

VS Pending Tests

Automated GUI Testing

Automated Testing of Window Forms

Detecting Memory Leaks with DUnit