Showing posts with label virtualization. Show all posts
Showing posts with label virtualization. Show all posts

Monday, September 29, 2008

Snapshot in UI Testing

If you have experience in JUnit or other testing tools, you probably know the importance of setup and teardown methods. These two methods help build a testing environment. However, when it comes to UI testing, it is not the case. UI testing means taking a long time, boring, and random exceptions. What's more, every time an error occurs, which might be caused either by a typo or by the tested codes, the only solution is to start over again from the very beginning. This is boring!

If we could take a snapshot at certain points (which are called save points), we could easily get started from those points. It should be time efficient. It certainly save a lot of time otherwise wasted in setting up the environment again. What's more, you can benefit from reproducing some random errors. If a snapshot were taken just before it occurs, the error would probably show up again, which also helps reduce the number of bugs.

It is not too hard to implement such a system. There are various ways though. It can be implemented as a functionality of the testing tools, or it could be bounded with the help of underlying systems. One good candidate is the virtual machine. Most VMMs, including open source ones, have a similar function. Taking snapshot takes seconds to minutes, depending on the implementations of VMM and the size of the virtual machine. We could take multiple snapshots, and rollback to a certain one, and even make branches. Although making use of VMM might seem easier, it is harder, but necessary, to integrate the snapshot into the testing tools. Taking snapshot should be as simple as setting breakpoints in debug. 

Saturday, July 26, 2008

Seamless mode of virtual machines could be improved.

Thanks to Windows, we are so used to Ctrl+Tab. (What? You are using a device called mouse?)

Virtual machine has advantages over host machines, though it is usually because of the users rather than the OS itself. Consider the case that you are using Linux as your host OS, but you would also like the the benefits from Windows, besides you get an licensed version. You might be using VirtualBox, or VMware products. They both have a seamless mode which integrates the guest OS into your host OS. This blurs the edge between the host and the guest. You might not notice that the applications are running on different machines. I could watch from Windows Media Player and update my Ubuntu at the same time.

All seems good before you come to a keyboard-only guru. The 'Ctrl+Tab' simply won't work when you want to switch between host and guest. The focus will not be released, when it is captured by the guest, unless the 'host key' is pressed. This is not an idea 'seamless' mode, where even gurus will not notice the switching from guest from host.

There are two possible trends of seamless mode for virtual machines on Linux. One is to make use of workspace on Linux. A workspace is like a separate root window on windows and the number of workspace can be changed by users. A virtual machine could use one entire workspace for the guest OS. This is especially convenient if the guest OS is a single workspace operating system. Another possibility is to make guest applications more like host applications. This is similar to Wine. However, one might still want to keep the original theme from guest OS.

A 'seamless mode' is a very good start point for improved user experience.
A screen shot of seamless mode of VirtualBox.

Tuesday, March 11, 2008

Virtualization and Video Card

Virtualization helps utilize the computer power. (It would consume more power, than a single server, but much less compared to a group of single servers). Virtualization is a cost-effective solution.

Although there are great enhancement of virtualiztion technology, there is not so much in the field of video virtualization. So far, no released virtual machine could provide a modern video card. What they do provide is an emulated slow video card with likely 8mb ram or even worse. It has limited the usability of virtual machine. For example, a game user certainly could not play his/her most favorable 3D game on such a VM. An 8mb ram might not be sufficient to render a quite large LCD. Further more, many CAD software requires a compatible video card.

There are other possibilities. When CPU and main memory are fast enough, the GPU could be replaced. Thus, things will be simpler. Only an average video is necessary.

It would be great for people requiring the flexibility of *nix who can't live without games which only have windows versions. In an ideal world, users would be able to
  • switch between VMs as easy as a simple click;
  • run any application at native speed;