Book Image

Advanced UFT 12 for Test Engineers Cookbook

Book Image

Advanced UFT 12 for Test Engineers Cookbook

Overview of this book

Table of Contents (18 chapters)
Advanced UFT 12 for Test Engineers Cookbook
Credits
About the Authors
About the Reviewers
www.PacktPub.com
Preface
Index

Checking whether page links are broken


Links are the most essential elements on a web page, as they are the connection between different sections on a page, other pages, and external pages. A link must lead to a valid Uniform Resource Locator (URL). If it leads to a non-existing or otherwise unavailable page, then it will be marked as broken.

A link that is a permanent element of a page is also called a permalink. Such a link is expected to always appear on a web page, and it will always lead to the same URL. Such a link is easy to map, either with OR, or using descriptive programming. However, in many web applications, links lead to dynamically generated pages, such as customer information, search results, and so on. Needless to say, their href attribute is also dynamically built, based on data that is known only during runtime. On a search results page, such as those generated by Google and other search engines, even the number of links may vary. This is also true for billing information...