views:

72

answers:

2

Currently, I am writing an application that utilizes WMI to scan all the computers on our Active Directory network.

I'm interested in testing the program against all flavors of Windows machines in a testing environment.

Is there a way to similuate this environment in VMware or something?

Any ideas?

A: 

You have two options.

  1. You probably have it right, with VMWare this is easy, try looking for cloning tools. If you plan on copying and pasting the image, you will get several problems (computer Guids repeated, Network Computer Names repeated, etc)

  2. You can also "mock" the WMI response by wrapping the WMI methods that you want to call and implementing an interface, using Rhino Mock or NMock if you are working in .NET (which I assume you are).

jpabluz
Since the question is about testing the WMI usage against different flavors of windows, mocking out WMI would specifically take out the component that is being tested.
Sam
You assumed correctly, however Sam is right. WMI is the main thing I'm testing here.
Paperino
+2  A: 

VMWare works well and can host many virtual computers on a single physical computer. You can also put the virtual computers on your active directory network.

If your goal is to set up a separate large network for testing that has it's own AD server you can look into Amazon EC2 for testing. The advantage here is once you setup your set of servers, you can turn them on and off as needed and only pay for the time actually used ($0.12 per hour).

http://aws.amazon.com/

Sam
Interesting! I didn't even consider doing this on EC2. Do you have any documentation of someone doing something like this on EC2 that I could look at?
Paperino
Amazon has lots of documentation on the website I mentioned. Each instance is a full server, you can install whatever software you want on each. Once you have it setup the way you like, you can clone it. But I think from your question you want to setup different instances with different OS's.
Sam
One warning about EC2 is that they don't offer many different versions of Windows - Server 2003 and Server 2008 are the only current versions available.
gareth_bowles