Questions tagged [ios-ui-automation]

Automated UI Testing using the Automation instrument included with Instruments for iOS development. Not to be confused with [xcode-ui-testing] which was introduced in Xcode 7.

Instruments is an application shipped with Xcode and used to help profile applications in both iOS and OS X development. One of the tools included with Instruments is the UIAutomation instrument which allows for automated testing of user interfaces using scripts written in JavaScript. This functionality was introduced with the iOS 4 SDK.

This tag specifically focuses on using this functionality in relation to iOS development. These scripts can be used not only to automate a user's interaction with the application, but they can also contain asserts which can test if the application is behaving according to the developer's expectations.

For the new Xcode 7 UI Testing feature, see .

756 questions
5
votes
2 answers

Setting accessibility identifier on a xib file

I have a xib file which has a view. Under a view, I have few labels... I am working on UIAutomation and hence want to add accessibility identifiers to the view and each of these labels. How can I do it inside the xib? I googled and found that a…
tech_human
  • 6,592
  • 16
  • 65
  • 107
5
votes
3 answers

How to deal with the "_APPNAME_ Would Like to Use Your Current Location" alert through UIAutomation

Ok, this is driving me nuts. I've got a little CI-build system running. And I'm doing UI testing of my application with UIAutomation. Since the application uses CoreLocation, the first time the application is launched I get a little alert asking me…
carlossless
  • 1,171
  • 8
  • 23
5
votes
2 answers

UIACollectionView cells vs visibleCells

I'm trying to write a test script using automation in xcode 4.5. I have a UICollectionView and I want to click on some cell not currently visible. Per documentation, I should expect cells to return all cells in the collection view, and visibleCells…
marmor
  • 27,641
  • 11
  • 107
  • 150
5
votes
3 answers

iOS UI Automation for different languages

my iOS application has localization for 10+ languages. I'd like to check that all screens looks ok (labels aren't too long/short etc). I know I can go through my app and make screenshots using UI Automation. Is there any way do switch simulator's…
OgreSwamp
  • 4,602
  • 4
  • 33
  • 54
5
votes
1 answer

UI automation tools for iOS apps that can identify CALayer objects

I'm trying to automate tests that test an app that has CA Layer objects. UI automation framework given by Apple does not identify CA Layer objects. I want a list of ui automation tools that help in identifying CA Layer objects. Can I get the list of…
5
votes
0 answers

Running UIAutomation scripts on multiple iOS devices via Instruments command line

Are there any way to run UIAutomation scripts in multiple connected iOS devices? Currently I use instruments with -w switch along with UDID of each device? I appreciate your ideas.
Arun
  • 336
  • 5
  • 14
4
votes
1 answer

iOS Automation Tests: buttons' Label not recognized by Instruments

I'm currently working on an automation script (JavaScript) for an iOS app. I'm not a programmer, just a tester who wants to seek bugs. Software concerned: Xcode, Instruments. Here is the problem: there are buttons in my application that had no name,…
4
votes
2 answers

iOS UIAutomation Failed:The target application appears to have died

I occasionally got this failure message "The target application appears to have died" from iOS UIAutomation, i tried to dig out the root cause, but after lots of trying, still could not be able to find it, does anybody have this same problem as i…
jianinz
  • 163
  • 1
  • 11
4
votes
2 answers

UIAutomation testing with Cocos2d, possible?

Is it possible to use UIAutomation with cocos2d or any opengl application for that matter? Specifically I want to use the zucchini framework to test my cocos2d game but that just uses UIAutomation anyway.
Christian Schlensker
  • 21,708
  • 19
  • 73
  • 121
4
votes
0 answers

Secure Textfield value in UIAutomation script

I have a login screen with username field and password field. In the UIAutomation script i have accessed the password field as var passwordField = window.secureTextFields()["password"]; But when i accessed the value of passwordField after entering…
PgmFreek
  • 6,374
  • 3
  • 36
  • 47
4
votes
1 answer

how to create a nested logs in UIautomation ios

How to create a nested logs in UIautomation ios like the one produced by logElementTree() I tried doing the following: UIALogger.logStart("Log parent Started"); UIALogger.logStart("Log child Started"); UIALogger.logMessage("Message…
4
votes
1 answer

Which processes can be launched using performTaskWithPathArgumentsTimeout function?

I use UIAutomation to automate an iPad application. I have tried to use (object) performTaskWithPathArgumentsTimeout(path, args, timeout) to run Safari.app from my script: var target = UIATarget.localTarget(); var host = target.host(); var result…
ele
  • 41
  • 2
4
votes
2 answers

UI Automation command line configure which simulator for universal app

I've got some UI Automation tests for a universal app that I'm running from the command line. They are working great, but the command line always launches the iPad simulator, and I'd like to be able to run them on both the iPhone simulator and the…
Brian Yarger
  • 1,965
  • 18
  • 17
4
votes
1 answer

Is there a UI Exerciser for iOS like Monkey on Android?

I'm looking for a development tool that will allow me to send randomly generated user inputs (touches, hardkeys, gestures) to an iOS devices (not simulator) like Monkey on Android.
smith324
  • 13,020
  • 9
  • 37
  • 58
4
votes
7 answers

Are there any existing library for Automation of UI controls in IOS

I am very new to IOS programming. I have a task to find if I can automate my UI for testing. This is what I want to do: Put some code in my application that randomly (sounds bad but may be pre-defined events)sends event messages to controls on the…
Lalith
  • 19,396
  • 17
  • 44
  • 54