Skip to content

Latest commit

 

History

History
41 lines (27 loc) · 1.03 KB

File metadata and controls

41 lines (27 loc) · 1.03 KB
description
Learn how to use the I.count command to count the number of occurances of texts in your UIlicious test.

I count Command

I.count

Assert the number of occurances for a text or element

Aliases: I.seeCount

Ignores casing and white-spaces. This behavior is not configurable at the moment.

Usage

I.count(target, n)

Parameters

Parameter Type Remarks
target string Text or element to find
n number Number of occurance expected

Example(s)

I.count("Add to cart", 20);

Asserts that there's 20 occurances of the text "Add to cart".

I.count(".product", 20);

Asserts that there's 20 occurances of the element with the "product" CSS class.