QTP Synchronization Topics


When we run out application at that time out application may not respond with the expected speed.

For example: 

  1. Progress bar to reach 100%.
  2. Status message to appear.
  3. Button become enable.
  4. Pop up window message to appear.
We can handle these timings problems by synchronizing your test script to ensure that quick test professional waits until web application is ready before performing any step.

We are having three synchronizations:

  1. Synchronization point.
  2. Wait and Exist.
  3. Increase time out.
Synchronization Point

 It is instruct QTP to stop the test until object property achieves the value in particular application.
We can use this option to provide waiting time  to the QTP based on particular object property.


Browser("Browser name").page("page name").waitproperty "text","successful message",time in millisecond.

Steps to generate Synchronize point:

1.Place the cursor in required place of script.
2.Click on Start Recording
3.Click Insert-->Synchronization
4.Show object with hand icon
5.Press OK
6.Select Property name[Enable]
7.Enter property value[true]
8.Timeout in milliseconds
9.Press OK
10.Stop recording

Wait is used to wait qtp untill object found according to specified time


Browser("Browser name").page("page name").Sync
Wait(5) //5 in milli seconds
Browser("Browser name").page("page name").WebEdit("Password").GetROproperty("text")

No comments:

Post a Comment