Then I should see "value" in the "text" element by attr

This step definition is used to be sure that the specified element has a specific value, identified by its attribute.

Then (I|we)* should see "([^"]*)?" in( the)* "([^"]*)?" element by( its)*( "([^"]*)?")* (attribute|attr)

 

Example:

Then I should see "1234" in the "pwordcss" element by attr

 

Or match any of the field attributes:

 

Then I should see "value" in the "text" element by its "id" attr

Example:

Then I should see "John Smith" in the "uname" element by its "id" attr