Steve Trefethen
Contact me
About Me View my LinkedIn profile

Powered by discountASP.NET
referal ID: sdtref
Why recommend discountASP.NET?
Need consulting?
Need Consulting?

Spread Thunderbird

Disclaimer

The posts on this weblog are provided AS IS with no warranties, and confer no rights. The opinions expressed herein are my own personal opinions and do not represent my employer's view in any way.

TestComplete Keyword Testing Online Training

I will be presenting a three day webinar April 12-14th 2010 from 9am-1pm PST on AutomatedQA's TestComplete. The cost is $499/person and you can register on Falafel Software's website here. For detailed information on this training click here.

HTTP Load Testing with AutomatedQA's TestComplete 6 and Remote Agent

January 11 2008 8:54AM
TestComplete Online TrainingPart of my job at Falafel Software is training on AutomatedQA’s TestComplete. Recently, I was teaching a class where the client was interested in HTTP load testing for which Test Complete has great support. Test Complete ships with a tool called Remote Agent that can be installed separately and allows for HTTP load testing using virtual users on multiple machines all controlled by a single instance of TestComplete. In fact, you can load test with up to 250 virtual users allowing a single tester to easily leverage an entire network of computers.

The following outlines the steps I took to demonstrate how easy it is to setup and execute HTTP load tests.

Setting up an HTTP Load Test ProjectTestComplete Project Manager

The first step is to create a new HTTP Load Test project.
  1. Select File | New Project
  2. Click the HTTP Load Testing Template
  3. Click Ok
  4. The Project Wizard appears and you can simply click Finish which will give you a project that looks like the image to the right.

As you can see the project has several nodes by default.

  • Stations: represents the machines that will be conducting the tests. Master is my current machine, the one I'm running TestComplete on.
  • Tasks: is the HTTP traffic you’re interested in testing.
  • Tests: allows you to assign tasks to various stations for test execution.
  • Scripts: is for manually writing test automation.

Setting up Remote Agent

For this example, I’m using a virtual machine running Windows XP. I’ve installed TestComplete 6.0 and I’m running Remote Agent which runs in a console window on the desktop. If you’re going to try and duplicate my setup be sure that your VPC network adapter is not set for Shared networking (NAT).

image The next step is to setup the machines you’ll use for load testing under the Stations node of your project.

  1. Right click the Stations node and select Add New... (you should see the dialog to the right)
  2. Enter the IP address of your Remote Agent machine, in my case that’s 192.168.1.104.
  3. Click Ok

This will give you a new node under Stations, "VPC" which is your VM, or the machine running Remote Agent.

Record an HTTP Task

The next step is to create the HTTP traffic you want to load test your server and the easiest way is using TestComplete’s recording facilities. For HTTP load testing this requires setting TestComplete to be a proxy for your web browser.
  1. Configure Internet explorer to use TestComplete as a proxy allowing it to monitor and record HTTP traffic. For IE you can do that from the Connections tab of the Internet Options dialog setting the proxy to localhost on port 9999. For Firefox open the Tools|Options dialog and look on the Advanced page, under the Network tab.
  2. Click the record button on the TestComplete toolbar and once recording begins click the "Record and HTTP Task" button (circled in red below):
    image
  3. This will bring up the Select Load Testing dialog where you can decide to record a new HTTP traffic or append it to an existing task.
  4. Once you click OK you can begin recording HTTP traffic by simply using your browser. TestComplete will record the HTTP traffic and add it to the task you specified.

Once recorded you can modify the web requests to fit your needs. Here is an example of what the recorded HTTP traffic looks like:

image

Running HTTP Load Testing

The next step is to configure individual Stations to perform the Tasks you’ve created. To execute your tests, TestComplete sends the recorded HTTP traffic to the web server bypassing the browser which means clients hosting Remote Agent will have no UI appear on screen other than the agent itself.

image

As you can see I’ve configured one virtual user to sent HTTP traffic starting half a second after the Master with a User-Agent of IE6.

Running HTTP Load Testing

The final step is to run your HTTP load tests and examine the output. To do that you can simply right click your test under the Tests node in the Project Explorer. The results at first will appear overwhelming but undoubtedly provide you with a detailed report of how you server performed.

image

Wrap up

As you can see TestComplete makes it quick and easy to create and run HTTP Load Tests so if this is something you’re looking for you might want to give it a try. Fwiw, Falafel Software offers TestComplete at a 10% discount in case you’re interested as well as online and onsite training. Feel free to contact me for more information.

[UPDATED: Jan, 17 2008] Fix a few typos, and clarify adding a new Stations node.
Digg It!DZone It!StumbleUponTechnoratiRedditDel.icio.usNewsVineFurlBlinkList

Tags: , , Automation | Testing

Bandwidth speed consistently faster in IE than Firefox is a USB drive to blame?

August 06 2007 5:19AM
linksys wrt150n
I recently purchased a LinkSys Wireless-N router ($99 on sale at Radio Shack) so I can roam around the house with my laptop. As a result I decided to do some bandwidth testing using broadbandreports.com's speed test as there is a server in Palo Alto, ~26 miles from my home, and it seemed like the results I was getting from Firefox were a bit slow. I started up IE to do some comparisons and found a not insignificant difference. As you can see on the graphic ComCast is my ISP which is easily three to four times as fast as what I was getting with my old DSL connection.

Results Using Internet Explorer 7.0.6000.16473

Results Using Mozilla Firefox 2.0.0.6

These results have been fairly consistent across a number of tests. I'm wondering if there is perhaps a performance penalty for running Firefox from a USB drive? All of these tests were conducted on my laptop.

I'll have test again at the office (also wireless) tomorrow and see how things compare. Of course, I'll probably install Firefox for a true apples-to-apples comparison.

Digg It!DZone It!StumbleUponTechnoratiRedditDel.icio.usNewsVineFurlBlinkList

Tags: , ,

Vista's Windows Experience Index and the Apple MacBook Pro

July 18 2007 6:32AM
I thought readers might find this interesting so here is a screen capture of the Windows Experience Index for my MacBook Pro (my work machine). Btw, the more I use this machine the more I like it, Apple has done a very nice job getting the drivers working for all of this machines features. I have yet to run into any sort of hardware related problem, everything just works. If you ask me, these numbers look pretty good. I'll have to ping Mark Edington and see if I can get him to get me a screen capture of my old "mainframe box" at CodeGear for comparison (apple to oranges, er Dell's but still).Windows Vista Experience Index MacBook Pro
Digg It!DZone It!StumbleUponTechnoratiRedditDel.icio.usNewsVineFurlBlinkList

Tags: ,

Community contributions improve Delphi 2007 RTL performance

February 27 2007 1:52PM
One of the areas I've worked on in the Delphi 2007 release is the inclusion of Delphi Community RTL contributions. Now, including community contributions is not new to Delphi. In fact, there is a project called FastCode which is dedicated to providing highly optimized, high quality replacements for existing RTL routines. With Delphi 2007 we've replaced the following RTL routines with code from our user community including the FastCode project under an MPL 1.1 license which is consistent with previous community contributions:

Contributor(s) Routine
FastCode and Pierre le Riche SysUtils.CompareStr
FastCode and Pierre le Riche SysUtils.StrLen
FastCode and John O'Harrow
SysUtils.LowerCase
FastCode and John O'Harrow
SysUtils.UpperCase
Pierre le Riche
System._LStrCmp

Since this release is interface compatible with BDS 2006 we had somewhat less flexibility to take RTL replacements but the door will swing back open with our next release and I'll continue integration of these great contributions.
Digg It!DZone It!StumbleUponTechnoratiRedditDel.icio.usNewsVineFurlBlinkList

Tags:

Delphi 2007 desktop switching performance improvements

February 24 2007 6:46PM
The Delphi/BDS IDE supports saving of desktops, or window layouts, via a dropdown list available from the main toolbar. These desktops allow you to control which windows are visible and arrange their size, position and docked location. For example, here is my design-time layout:

Delphi IDE design layout

As you can see I use the "undocked IDE" meaning my code editor is free floating, not docked into the top main toolbar window. I actually like the docked IDE but I prefer to do everyday work using the undocked layout to make sure it's always getting tested.

Now About the Perf...

The other day Mark Edington our performance cop recruited me to help with tuning the performance of switching desktop which I mentioned was keeping me busy on Tuesday. This morning I checked my email and Mark had done some timing of my new code and found "The general average seems to be that things are approximately 30% faster". Cool! Couple this with the flicker work I've been doing and I think the Delphi 2007 experience is going to be much nicer.
Digg It!DZone It!StumbleUponTechnoratiRedditDel.icio.usNewsVineFurlBlinkList

Tags: ,

Delphi IDE and RTL/VCL performance improvements

February 09 2007 7:12AM

Lately, there's been a lot of effort put into improving the Delphi IDE's UX and I wanted to comment briefly that in the past week alone we've made some great progress. For example, there have been recent improvements in:

  • IDE flicker (now nearly flicker free)
  • Desktop switching performance
  • GDI resource management
  • Moving controls on the form designer via the keyboard
  • Form designer grid repaint issues
  • Compiler time stamp access (thanks to Andreas Hausladen)
  • VCL control painting (thanks to Pierre le Riche)
  • VCL control data handling performance
  • FastCode routines added to the RTL (btw, a huge thanks to the whole FastCode crew who contribute to this great project benefiting us all)
One of the best things about a number of these fixes is that they're in the RTL/VCL so your applications will benefit as well. Btw, several of them came from QC so it definitely pays off to get your bugs logged. Anyway, we're cranking away and there's more to come but I'm pleased with the progress and thought it was worth mentioning.
Digg It!DZone It!StumbleUponTechnoratiRedditDel.icio.usNewsVineFurlBlinkList

Tags:

Using the WS_EX_COMPOSITE window style to eliminate flicker on Windows XP

February 05 2007 6:38AM
As I continue to work through the various flicker issues on individual controls in the VCL I thought it worth mentioning a bit more "global" way to tackle the "flicker" problem. If you're running Windows XP there is a window style called WS_EX_COMPOSITED which you'll find documented on MSDN under CreateWindowEx here. This style bit instructs the OS to apply double buffered painting for you. Here is how you would add this to a Delphi VCL form:
1 type 2 TMyForm = class(TForm) 3 protected 4 procedure CreateParams(var Params: TCreateParams); override; 5 end; 6 7 ... 8 9 procedure TMyForm.CreateParams(var Params: TCreateParams); 10 begin 11 inherited; 12 // This only works on Windows XP and above 13 if CheckWin32Version(5, 1) then 14 Params.ExStyle := Params.ExStyle or WS_EX_COMPOSITED; 15 end; 16

You should be able to use this on any 32-bit version of Delphi as long as your app is running on Windows XP.

The downside is that depending on your application this change could have rather serious performance implications during a window resize particularly with aligned controls. The upside of course is that it's flicker free! :-)

I've read that there may be some issues related to using this window style with GDI+ so be sure to look for that if it affects you.

There is no comment on the MSDN as to how this works under Windows Vista but I'd guess there may be some differences.

[UPDATE: May, 2008] Related posts:

Quick Tip: FullRepaint and fixing flicker in a Delphi VCL app
Quick Tip #2: Fixing flicker caused by WM_ERASEBKGND in a Delphi VCL app
Digg It!DZone It!StumbleUponTechnoratiRedditDel.icio.usNewsVineFurlBlinkList

Tags: , ,