Skip to main content
Hero Background Image

Using VMs for Quick and Reliable QA

July 16, 2013

When cross-browser testing a website, you clearly need access to the relevant browsers. While it’s possible to run Internet Explorer in different rendering modes, why not use a solution that runs the native app in an environment that allows you to reset the browsers to a known clean slate and will reproduce all of the font rendering issues that you’d like to catch?

It turns out that Microsoft now provides cross-platform virtual machines for Windows XP through Windows 8. With some setup time and snapshots, you can have browser-cache proof installs of a whole suite of browsers to test, each with surprisingly short launch times. This quick guide will be targetted for VirtualBox, a virtualization tool that runs in all of Windows, OS X, and Linux. However, extending the concepts to VMWare and other virtualization products shouldn’t be a stretch.

Step One

Head to Microsoft’s to download the virtual machines you’d like to install. The instructions there for importing the virtual machine are quite complete, so it should be a snap to get the VM running.

Step Two

Update your virtual machine with any browsers and initial configuration that you’d like to have. I open up all of the browsers I test against to a blank page; this lets me quickly switch between them to test whenever I launch the VM. VirtualBox allows for a great branching system of snapshots, so don’t worry if you need to tweak this later as you get used to it.


Step Three

Take your snapshot. VirtualBox implements this as a camera icon in the right panel of the manager.


Step Four

Whenever you’d like to test against your virtual machine, simply select the snapshot and click “Start”. Your VM will load exactly as it was, giving you quick access to the browsers you set up—which means that if you never visited the sites you’re working on before you took the snapshot, you’ll never have to worry about clearing your browser cache. When you’re finished, simple close the VM and select “Power off the machine” and “Restore current snapshot …”. This will reset the virtual machine to its clean slate, ready to be used next time.

 Once your virtual machines and snapshots are set up, you’ll have a wide range of platforms at your fingertips to test. In fact, if your test targets include Linux or other operating systems, the exact same ideas apply.

Happy testing!

Additional Resources

Why QA Your Website?

SSH Tips and Tricks Part 1 - The Fundamentals