EarlGrey is a functional user interface testing framework for Apple iOS apps that has been introduced by Google.
EarlGrey has been open sourced under the Apache license, according to Google’s Siddartha Janga. The company has provided app developers with a start guide and the ability to add EarlGrey to their projects using CocoaPods or to add it manually to Xcode project files.
The main advantages to EarlGrey is its synchronization ability, noted Google’s Janga. The tests automatically wait for animations, network requests and other events before interacting with the UI. That makes it easier for app developers to write tests without sleep or wait states and to maintain a procedural description of test steps.
Two other factors — visibility checking and design flexibility — enhance the testing process on the iOS platform.
Visibility checking during tests takes into account the user experience with an app. It ensures, for example, that attempting to tap a button hidden behind an image will flag an immediate failure, Janga said.
Design components involving element selection, interaction, assertion and synchronization take future growth into consideration.