Verify text color in iphone uiautomation
Asked Answered
S

2

14

I am testing an app with ios uiautomation and I need to verify the color of some static text controls. Is this possible? I didn't see any methods or properties that allow access to text styling.

Slumberous answered 20/6, 2011 at 19:48 Comment(2)
I'm interested as well. See #6504858Soulless
are the controls you're trying to test standard or custom?Hypolimnion
M
1

I don't know how much you have already implemented using UI Automation, but if you have not yet invested too much I would strongly recommend using FoneMonkey instead. It has an excellent script recording facility, outputs Objective C/SenTestCase scripts, and the scripts have full access to the internal of your program so that you can test color or any other property you like. It is easily extensible, and I have also generally found it to be much less of a pain to work with than UI Automation.

Muoimuon answered 24/8, 2011 at 8:42 Comment(0)
C
0

There is no way to do this using standard accessibility on iOS. You could modify the accessibilityValue for the element with a string representation of the color, but this seems like it would create a poor experience for vision impaired users.

Coly answered 19/11, 2013 at 18:58 Comment(0)

© 2022 - 2024 — McMap. All rights reserved.