0

I'm doing some UIAutomation testing using Xcode Instruments and have an issue accessing a staticText which I want to verify.

The situation: I have some buttons that display different scroll views that contain multiple charts. These scroll views have 5+ items in each so when i initially do target.logElementTree() it only shows the visible ones. If i scroll down with window.scrollViews()[0].scrollDown() and again get a logElementTree() the bottom elements are shown however whenever i try to access them it keeps referring to the ones from the top of the scroll view.

Any ideas?

Cheers.

Display Name
  • 4,502
  • 2
  • 47
  • 63
Sae Us
  • 277
  • 1
  • 6
  • 21

1 Answers1

0

As per as my experience, whenever you do "taregt.logElementTree()", it will display you all the elements (visible & hidden or which are present even at the bottom of screen) which you can access by its name or index or position once scrolled down. But if you still face problem, I will recommend you to access the element by its position after scrolling down to make it visible.

San27
  • 223
  • 2
  • 7