Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Negative Tests - Checking for links which should NOT be present.
#4
Solved: 11 Years, 3 Months, 1 Week ago
I resolved my problem

Code:
IF  Browser("My Web").Page("Reporting").Link("Update and Check").Exist(4) THEN
    reporter.ReportEvent micFail, "Admin Links", "Admin Links should only be available for Admins"
ELSE reporter.ReportEvent micPass, "Admin Links", "This is correct as no Admin Links are available"
END IF

I am using QTP 9.5, If anyone knows of a better way of doing this please let me know.

Thanks
Reply


Messages In This Thread
RE: Negative Tests - Checking for links which should NOT be present. - by Kartal - 12-09-2010, 09:25 PM

Possibly Related Threads…
Thread Author Replies Views Last Post
  Adding negative amount in webedit Rose 1 2,113 06-30-2016, 09:34 PM
Last Post: babu123
  [UFT] Fixed web tests with dynamic parts jdd 3 2,570 04-05-2016, 02:56 PM
Last Post: vinod123
  How to check expected cookies are present or not priyanka.agarwal 0 1,947 07-02-2015, 12:43 PM
Last Post: priyanka.agarwal
  This code does not give total no of links present on page plz help it returns 0 excellentpawan 8 5,569 01-17-2015, 07:49 PM
Last Post: yogi4tech
  how to get a link present under mouseover action priyadarisini 1 2,290 12-03-2013, 08:59 PM
Last Post: Parke

Forum Jump:


Users browsing this thread: 1 Guest(s)