Performance Testing Evaluation Guide

Aug 24 2009 12:04:13 AM Posted By : Raghavan
Comments (0)

Hi All,

We have published Performance Testing Evaluation Guide in the QEngine website in the below link,

http://www.manageengine.com/products/qengine/web-performance-evaluation-guide.html

or You can download it as PDF from the below link,

http://www.manageengine.com/products/qengine/web-performance-evaluation-guide.pdf

Raghavan

If you encounter the dynamic windows in the UI automation, you can easily handle them.

Here are the functions available

Code:
setDynamicWindow(parenttitle,parentindex=1,framepropertyname="NONE",framepropertyvalue="NONE",frameindex=1)
closeDynamicWindow(parenttitle,parentindex=1)


If more than one window is present you can use parentindex and frameindex to choose which window.

However, consider this situation. You don't want to enter the title of the window or title keeps changing. What to do in this case?

We need to use the following functions to handle such cases.

Code:
getLastWindowTitle()
getWindowTitle()
getWindowURL()
getLastWindowURL()


I hope the function names are self explanatory. However, we need to use setLastWindow function once we changed the focus.

Example 1.

If the dynamic window doesn't have any inner frames.
Code:


setDynamicWindow("Test page",1,"NONE","NONE",1)

closeDynamicWindow("Test page",1)


Example 2.

If the dynamic window has any inner frames.

Code:


setDynamicWindow("Test page",1,"title","mypage",1)

closeDynamicWindow("Test page",1)


Now consider this case. Windows title is not known or can't be predicted.

Example 3.

Code:

gwt=getWindowTitle()

gwtn=getWindowTitle()
if gwt!=gwtn:
setDynamicWindow(gwtn,1,"NONE","NONE",1)

closeDynamicWindow(gwtn,1)

or

Code:


gwt=getLastWindowTitle()
gwtn=getWindowTitle()
if gwt!=gwtn:
setDynamicWindow(gwtn,1,"NONE","NONE",1)

closeDynamicWindow(gwtn,1)


You can add more conditions if needed

Example 4.

Code:


gwt=getLastWindowTitle()
gwtn=getWindowTitle()
if gwt!=gwtn and gwt!= and gwtn!=:
setDynamicWindow(gwtn,1,"NONE","NONE",1)

closeDynamicWindow(gwtn,1)


This will ensure that dynamic windows are taken care without knowing the window title.

Rajasankar
rajasankar at zohocorp dot com

Why to Parameterize in Load Testing ?

Aug 17 2009 11:17:28 PM Posted By : Raghavan
Comments (0)

Hi All,

We received a good question from one of our customer. The question is

Why should i parameterize the transactions in Load Testing ?

It is indeed a nice question. Actually his question is, i am not configuring those parameters while recording. Then how do i know what are the parameters it takes and its value.

Here is the solution. Yes the user don't know what are all the parameters it takes while submitting a page. Hence in QEngine we introduced a feature called Auto parameterization.

What is Auto Parameterization ?

Auto parameterization facilitates to automatically extract the parameters from the associated reference page and use it while submitting the particular page to the server.
This is what happens while submitting the page while browsing in the browser.

This feature will work perfectly for most cases.

But for some cases the server may require unique value for each virtual user. In those cases, you may be required to parameterize value for the username, password and those parameters which you input during recording in the browser.

For this QEngine easy to use user interface namely Parameterization screen. It will list all the parameters for each URL separately, thus user can easily configure the value for the parameters. QEngine provides various options to parameterize such as Dataset / Cookie / Java script / Previous Response Content / HTML Element / Random values etc.

To know more on parameterization look at the below URL:
http://www.manageengine.com/products/qengine/performance-testing.html

There are still more improvements can be done in parameterization. This will happen in future QEngine releases.

Raghavan


[/b]

There is an endless debate going on in the testing world regarding the strategy for automation testing. What to use, scripting or record/paly back tool?

Before commenting which one is best, we need to understand what are the pros and cons these two.

Let us see pros and cons of scripting

pros
1. Standard scripting language and standard library
2. No vendor scripting
3. Version Control
4. Running with own testsuite or with standard library

cons
1. Need to build from scratch
2. Time consuming process
3. Suited for individual need. May not be applicable to other software
4. Need to identify the elements from source manually.

For record/playback tool,

pros
1. Easy identification of elements
2. Maintenance will be taken care by vendor
3. Will come with utilities to run the test suite
4. Easy setup and running

cons
1. Maintaining the scripts is difficult.
2. Version control may not be available.
3. Vendor scripting may have a deep learning curve

Both the options offer some advantageous. If we can combine both, we can reduce time and do the things in a hassle free manner. That will offer best of both worlds, then it is easier to do automation, Isn't?

So the ideal tool should have the version control, minimal vendor scripting, options for one or more standard scripting languages. Next time when you evaluate an tool, check these options in it.

Rajasankar
rajasankar at zohocorp dot com

Vendor Script Functions in QEngine

Aug 17 2009 01:56:47 AM Posted By : rajasankar
Comments (0)

Vendor Script Functions in QEngine.

Before seeing what are the vendor functions, we need to understand what is Vendor Scripting?

Vendor Scripting defined as script/functions specific to the program or application. In other words, such functions available only in that application and won't be used anywhere else.

Vendor scripts can be a deciding factor in the learning curve of the automation tool. The more vendor scripting, more time needed to learn.

Here is the separation of vendor scirpt and common functions

1. Window Functions or Dynamic Functions
2. HTML Special Functions
3. HTML Check Functions or HTML Get Functions
4. AJAX Functions
5. Invoke Script Functions
6. General Functions (optional)
7. Default Recorded Functions(optional)

Common functions
1. XML Validation Functions
2. String Manipulation Functions
3. File Manipulation Functions
4. E-Mail Functions
5. Date Functions
6. Database Functions

Check this page for all functions available in the QEngine.

Rajasankar
rajasankar at zohocorp dot com

How to follow web links in Dynamic web page

Aug 13 2009 09:00:38 PM Posted By : rajasankar
Comments (0)

In this article, I am going to show, how to follow the web links in the Dynamic web page is easy with QEngine.

Here are the two function used in that.

You can get the DOM element property with the following function,

Code:
getElementProperty(tagName,propertyName,propertyValue,index,propertyNeeded,regExpRequired='false')

You can click on the element using the following function,
Code:
fireEventOnElement(tagName,propertyName,propertyValue,index,actionName,actionValue='',regExpRequired='false')

Here
tagName = DOM tag name such as TD,IMG,SPAN
propertyName= Property of the tag which is used such as Name,ID
propertValue= Value of the property.

First find the values in the page using getElementProperty,

Code:
getElementProperty("A","href",propertyValue,index,"href",regExpRequired='false')


Here the propertyValue is the one we don't know and that one we need. How to get this? Simple, use regex to get any value in href property.

Code:
getElementProperty("A","href",".*",index,"href","true")


Now this will match everything in that property and entire string. Let call this in a loop and get the values as an array.

Code:

i=1
while i>0:
values=[]
setLastWindow()
property=getElementProperty("A","href",".*",i,"href","true")
if property is not None and property!='':
values.append(property)
i=i 1
else:
i=0
return values


Now use the values in the fireEventOnElement function


Code:

for i in range(0,len(values)):
setLastWindow()
fireEventOnElement("A","href",values[i],i,"click","NONE","false")


You can also concatenate the web url if the value is relative.



Code:

for i in range(0,len(values)):
setLastWindow()
url="" values[i]
fireEventOnElement("A","href",url,i,"click","NONE","false")


Bingo!



You can use the same idea for any tag in the web page.

Let me know, how this works.

Rajasankar
rajasankar at zohocorp dot com

In Notepad you can add function complete for custom languages. Existing Auto Completion files can be edited too which means I can add QEngine functions too.

I've spent an hour to add the QEngine functions into python.xml file. Now, I don't have check the Framework.py for the syntax of the functions.

The QEngine script file has extension of .wcs, associate that to the python language and see the difference. Those files will be located in the /QE home/projects//webscripts/< script name>/.

Here is the file, change the extension into .xml and replace that under /Notepad home/plugis/APIs/.

This feature also available in the QEngine inbuilt editor. If you need this one for any other text editor, let me know.

Rajasankar
rajasankar at zohocorp dot com

Recently we received a query from a customer how could i check if the particular element is displayed in the web page or not.

We suggested them to use doesElementExist function for the above query. But in her case it always returned the Success. So we analyzed the problem and found the element she is referring is exist in the webpage, but its display property is toggled to show / hidden the element in the web page. If it is shown then the display property is block. If it is hidden display property is none.

Hence we thought to suggest her to use styleCheckInfo where it will validate the display property of the particular element and tell you whether the element is displayed or hidden in the web page.

Very recently in QEngine we given customization option to retrieve the style properties of the element from the web page. It will be huge to retrieve all the style properties of an element from the web page. Hence we thought to give the option to the user so that he can define whatever the properties he is interested in.

Hence under Recorder Settings we have given an option to define the style properties he interested to retrieve from the web page.

Coming back to the problem,

To validate an element is hidden in the web page use the following function,

styleCheckInfo("","display","none")

To validate an element should be visible in the web page,

styleCheckInfo("","display","block")

Hope this will be helpful to validate the element presence in the page.

Raghavan

QEngine 7.0 Released

Jun 29 2009 03:50:48 AM Posted By : Raghavan
Comments (0)

Dear All,

We are pleased to announce the release of QEngine 7.0.

There are lot of new features added in this release.

Main Highlight of this release is Automation support in IE 8 and Firefox 3.0 browsers.

Find more at what's new.

Download QEngine 7.0 and let us know your feedback.

Raghavan

Identifying Javascript Error using QEngine

Jan 08 2009 06:40:14 AM Posted By : Raghavan
Comments (0)

QEngine has the feature namely "Report Javascript Error in Reports", using which javascript arising in the web applications can be reported in the QEngine reports.

To configure to report the javascript errors follow the below instruction in QEngine,

Go to Settings page
Choose Exception Handling tab
Check the checkbox for "Report Javascript Error in Reports" and Apply the changes.

Now during playback if there is any javascript error arise, it will be notified in the reports.

Thanks & Regards,
Raghavan