Micro Focus QTP (UFT) Forums
How can i test a website - Printable Version

+- Micro Focus QTP (UFT) Forums (https://www.learnqtp.com/forums)
+-- Forum: Micro Focus UFT (earlier known as QTP) (https://www.learnqtp.com/forums/Forum-Micro-Focus-UFT-earlier-known-as-QTP)
+--- Forum: UFT / QTP Beginners (https://www.learnqtp.com/forums/Forum-UFT-QTP-Beginners)
+--- Thread: How can i test a website (/Thread-How-can-i-test-a-website)



How can i test a website - saimram - 07-28-2009

Hi Friends:

I have used Hotmail.com, and i started to record and play by giving my user name and password, and next i clicked inbox to see the message contents here i have stopped recording and saved the QTP file,
At this point i have total 9 unread messages that is showing like
Inbox (9)
I read some 2 messages now the inbox count shows Inbox (7) and closed the hotmail

Next time when i run the script, it worked properly till username and password, but it fail saying that it is unable to recognize Inbox (9),

As now the inbox as 7 unread messages it is failing, how can make it dynamic so that what ever the unread message count is it should work?

Expecting to get an answer,
Thank you in advance.
Regards,

the error it is giving is that


RE: How can i test a website - manabh - 07-28-2009

Hi ,
You have to use regular expressions set to the controls added in object repository. Like the control showing "Inbox(9)" should be of Link type & you have to set regular expression for it as "(Inbox.*)"


RE: How can i test a website - braddmark - 09-09-2009

But how to use regular expressions set to the controls added in object repository?


RE: How can i test a website - Saket - 09-09-2009

open object repository
select the Test object (in your case may be a link object name Inbox(..))
You will see the description properties 'text' at object properties pane
select the value of text property, it must be inbox(..)
you will find a button( <#> ) appeared there click the button
new window will pop up, Check on the regualr expression there
say Yes if prompted.
you will get something like 'Inbox\(..\)'
delete every thing after Inbox\ and put a '.*' there
Click OK

That's it,
hope this will help you.

Request you to please serach in forums before creating a new thread. there is a similar thread available
Refer this
@braddmark - Please restrict yourself to divert a thread from the original question.
you should always try to open a new thread for the new query.

Also request you to please remove the link from your signature, any link which is not relevent to the forum/community is not allowed to be used either in signature or in the post content.


RE: How can i test a website - april198474 - 09-22-2009

Saket got the key point.
_________________________
april
[Url Removed]


RE: How can i test a website - Saket - 09-22-2009

hey April,

please do not advertise any url which is not at all relevent to the qtp and the community. Restrict yourself from posting such advertisements in any of the thread or in your signature. Refer posting guideline.