0

I'm using Mechanic.js framework with iOS UI Automation.

I have a cancel UIBarButtonItem. When I do this $("#Cancel").index(), the result is -1 which is not found. Am I missing something here? Just to clarify, $("#Cancel") does work by itself but .index() won't able to retrieve the right index.

Lebyrt
  • 1,376
  • 1
  • 9
  • 18
Infinity
  • 3,695
  • 2
  • 27
  • 35

1 Answers1

0

This is because Apple broke the equality operation on UIAElements (see also: this question), which Mechanic.js relied on in order to figure out the index of a found element.

Community
  • 1
  • 1
Ian
  • 11,280
  • 3
  • 36
  • 58