Using Checkpoints With Web Controls

Applies to TestComplete 12.60, last modified on September 17, 2018

Before publishing your web site, you may need to validate the markup of its pages, check the site for broken links, check whether the pages contain certain text and so on. The following sections describe how you can automate the checking and validation processes using checkpoints:

About Using Checkpoints in Web Testing

When testing web pages, you usually need to check different characteristics of web pages and their elements. Since TestComplete provides you with access to web page elements, their properties, attributes and methods, you can check any web page contents.

TestComplete includes a number of built-in checkpoints that enable you to verify various characteristics of a web page and its elements. You can create them in keyword tests and scripts when recording a test and at design time.

You can use any available checkpoints with your web pages. The commonly used checkpoints for web objects include:

  • Property checkpoint - enables you to verify web objects’ attributes and properties;
  • Table checkpoint - enables you to verify the contents of third-party tabular controls;
  • Web accessibility checkpoint - lets you verify whether the web page complies with the Web Content Accessibility Guidelines rules;
  • Web comparison checkpoint - enables you to verify web page contents;

If needed, you can also use any other checkpoint for testing your web pages. For a full list of the available checkpoints and their detailed description, see the About Checkpoints topic.

The rest of this topic describes common web page verification tasks and explains how you can automate these tasks with TestComplete.

Checking Web Elements’ Attributes

To verify the value of a web element’s attribute, you can use a property checkpoint. When creating a property checkpoint, you specify the desired web element whose attribute (or property or field) you want to check and then select the attribute to be verified. After that, you should specify verification parameters and the expected attribute value.

Tip: Note that native web attributes and properties are displayed only in the More Properties mode. Also, custom web attributes are not displayed in the Checkpoint Wizard. However, you can manually type the name of the needed web element’s attribute.

After you finish configuring a property checkpoint, TestComplete adds the corresponding checkpoint operation to your test. For a detailed description of creation of property checkpoints, see the About Property Checkpoints topic.

Verifying the Contents of Tabular Web Controls

Another typical task is verifying the contents of a control that displays information in a tabular form. Typically, such verification means comparison of the control’s actual content with a baseline copy. TestComplete supports table checkpoints for a number of third-party controls. For a full list of supported tabular controls, see Supported Controls.

Tip: If you need to check the contents of TABLE elements, you can download the "HTML Table Checkpoints" extension from our web site. This checkpoint automates verification of TABLE elements and lets you compare them with the baseline data.

When creating a table checkpoint, you specify the desired table object and specify the object’s data to be stored. TestComplete will create a Table element that contains the specified object’s data. If needed, you can modify verification parameters in the Table Element Editor.

After you create a table checkpoint, TestComplete adds the corresponding checkpoint operation to your test. For a detailed description of creating table checkpoints, see About Table Checkpoints.

Verifying Web Page Accessibility

Web accessibility checkpoints are used to verify a web page’s conformance to Web Content Accessibility Guidelines. A web accessibility checkpoint includes typical verification actions such as checking the ALT attribute, checking tab indexes, checking for broken links and so on. For a complete list of the available verification actions, see Web Accessibility Checkpoint Settings.

Verifying Web Page Contents

If you need to verify a web page against a baseline copy, use the web comparison checkpoint. When creating a checkpoint, you store a baseline copy of a web page and specify the comparison mode. Web Comparison checkpoints allow you to easily compare the whole HTML document, the tag structure of the specified page or the specified tags. For a detailed description, see About Web Comparison Checkpoints.

Further Reading

See Also

About Checkpoints
Testing Web Applications
Cross-Browser Testing in TestComplete
Common Tasks for Web Testing

Highlight search results