containing(_:identifier:)
Returns a new query that matches elements that contain a descendant of the requested type and an identifying property that matches a provided identifier.
Declaration
func containing(_ elementType: XCUIElement.ElementType, identifier: String?) -> XCUIElementQueryParameters
- elementType:
The contained element type to match.
- identifier:
An optional string to match against the contained element’s identifying properties: Identifier, Title, Label, Value, or Placeholdervalue.
Return Value
A new query that defines a search that extends the search criteria of the receiver. The new search finds elements that match the original search and contain elements of the requested type that have an identifying property that matches a provided identifier. For the list of the types, see XCUIElement.ElementType.