Ideas & Feature Requests

Share your ideas on how Test Cloud can better help you deliver higher quality apps faster.

Ability to query to find elements with by text property LENGTH (empty or non-empty)

Currently if you want to find elements, or wait until there is an element, with an empty or non-empty text property, there is no way to do that in a query. Instead you have to iterate through all elements that might match your criteria, and manually check the Text property of each element. This is problematic particular if you want to WaitFor that element. Imagine that you want to wait until a field marked "HeaderTitle" has had its text populated. (Imagine: Something is downloading in the background, and that field's won't be populated until the download has completed and the UI has been re-loaded. But it is not a blocking call; the app is usable meanwhile. So the best way to check if its done is to see if its text is non-empty.) At the moment you have to do something like (pseudo-code):

var elements = app.Query("HeaderTitle);
foreach element in result
{
// if element.Text.Length > 0
// break;
// else
// iterations++;
// if iterations > 120 seconds throw TimeoutException
// Thread.Sleep 1
}

This should be as easy as 

app.WaitForElement(x => x.Marked("HeaderTitle").Property("text").Length() > 0);
  • Guest
  • Jan 20 2017
  • Will not implement
Device Manufacturer
Device Model Name
Operating System Version
  • Attach files
  • Admin
    Justin Raczak commented
    January 23, 2017 22:41

    This request is specific to the test framework, rather than Test Cloud itself. While I am closing this issue, I have forwarded the request onto the test frameworks team. Thank you for providing such great detail!