iOS UI Automation Test Framework

Overview

Deprecation: EarlGrey 1.0 is deprecated in favor of EarlGrey 2.0 which integrates it with XCUITest. Please look at the earlgrey2 branch. EarlGrey 1.0 is not being maintained internally with iOS 13.

EarlGrey

Apache License CC-BY 4.0 License Build Status Carthage compatible CocoaPods Gem Version

For EarlGrey 2, please go to earlgrey2 branch.

EarlGrey is a native iOS UI automation test framework that enables you to write clear, concise tests.

With the EarlGrey framework, you have access to enhanced synchronization features. EarlGrey automatically synchronizes with the UI, network requests, and various queues; but still allows you to manually implement customized timings, if needed.

EarlGrey’s synchronization features help to ensure that the UI is in a steady state before actions are performed. This greatly increases test stability and makes tests highly repeatable.

EarlGrey works in conjunction with the XCTest framework and integrates with Xcode’s Test Navigator so you can run tests directly from Xcode or the command line (using xcodebuild).

Getting Started

The EarlGrey documentation for users is located in the EarlGrey/docs folder. To get started, review the EarlGrey features, check for backward compatibility, and then install/run EarlGrey with your test target. After everything is configured, take a look at the EarlGrey API and start writing your own tests.

Getting Help

If you need help, several resources are available. First check the FAQ. If you have more questions after reading the FAQ, see Known Issues. You can bring more specific issues to our attention by asking them on stackoverflow.com using the #earlgrey tag. You can also start new discussions with us on our Google group or request to join our slack channel.

Analytics

To prioritize and improve EarlGrey, the framework collects usage data and uploads it to Google Analytics. More specifically, the framework collects the MD5 hash of Bundle ID, Test Class Names and Test Method Names. This information allows us to measure the volume of usage. For more detailed information about our analytics collection, please peruse the GREYAnalytics.m file which contains the implementation details. If they wish, users can choose to opt out by disabling the Analytics config setting in their test’s - (void)setUp method:

In Objective-C:

// Disable analytics.
[[GREYConfiguration sharedInstance] setValue:@(NO) forConfigKey:kGREYConfigKeyAnalyticsEnabled];

In Swift:

// Disable analytics.
GREYConfiguration.sharedInstance().setValue(false, forConfigKey: kGREYConfigKeyAnalyticsEnabled)

For Contributors

Please make sure you’ve followed the guidelines in CONTRIBUTING.md before making any contributions.

Setup an EarlGrey Project

  1. Clone the EarlGrey repository from GitHub:
git clone https://github.com/google/EarlGrey.git
  1. After you have cloned the EarlGrey repository, download all the dependencies using setup-earlgrey.sh.
  2. After the script completes successfully, open EarlGrey.xcodeproj and ensure that all the targets build.
  3. You can now use EarlGrey.xcodeproj to make changes to the framework.

Add and Run Tests

Unit Tests

To add unit tests for EarlGrey, use UnitTests.xcodeproj located at Tests/UnitTests. To run all unit tests, select the UnitTests Scheme and press Cmd+U.

Functional Tests

To add functional tests for EarlGrey, use the FunctionalTests.xcodeproj located at Tests/FunctionalTests. To run all functional tests, select the FunctionalTests Scheme and press Cmd+U.

Comments
  • Add Support for Device Shake API

    Add Support for Device Shake API

    Implements #678. Added a functional test to test device shake.

    Note that at the time of cloning the project, numerous unit tests are broken and do not pass on iOS 11.)

    cla: yes lgtm 
    opened by LeoNatan 30
  • EarlGrey gem

    EarlGrey gem

    Fix #73

    The gem is still a work in progress. Carthage support is verified as working.

    Todo

    • [x] Write RSpec test
    • [x] Fix Ruby warnings
    • [x] Fix rubocop violations

    After merge

    • [x] More RSpec tests
    • [x] Run Ruby tests on Travis CI
    • [ ] Setup coveralls
    • [ ] Setup code climate -- works
    • [x] Research Gemnasium -- not supported
    • [ ] Update example to support carthage
    • [ ] Update cocoapods Podfile to use the gem
    • [ ] Update documentation to recommend using the gem

    Let me know what emails to add on RubyGems. Once added as a gem owner, you'll be able to make gem releases (rake release).

    cla: yes 
    opened by bootstraponline 23
  • EarlGrey 2.0 | Cocoapods | Can't run target app without UITests

    EarlGrey 2.0 | Cocoapods | Can't run target app without UITests

    Target app crashes on start if run alone (without UITests ex. by hitting cmd+R) and get

    Fatal failure: EarlGrey's app component has been launched without edoPort assigned. You are probably running the application under test by itself, which does not work since the embedded EarlGrey component needs its test counterpart present. in /Users/brettfazio/dev/reducingimports/EarlGrey/AppFramework/DistantObject/GREYHostApplicationDistantObject.m:93

    It can be reproduce in Example from earlgrey2 branch.

    Xcode 10.2.1 Swift 5.0 Cocoapods 1.6.1

    opened by konrad-zdunczyk-luxmed 21
  • `tap()` Action fails although target item exists

    `tap()` Action fails although target item exists

    i keep getting Reason: Action 'Tap' failed for tapping a UIButton subclass although target UIButton with the correct accessibilityId / accessibilityLabel exists and logged in window hierarchy dump after failure.

    Runs on iPhone5 simulator, iOS 10.2 , EarlGrey V1.3.0

    opened by haitham-reda 21
  • EarlGrey 2.0 Helper Bundle (Swift) can't find XCTest.h

    EarlGrey 2.0 Helper Bundle (Swift) can't find XCTest.h

    I set up EarlGrey 2.0 according to setup.md.

    In Helper Bundle Section, I added Bridging-Header for Helper Bundle, then I got compile error. Error message is 'XCTest/XCTest.h' file not found in XCTestCase+GREYSystemAlertHandler.h.

    How can i resolve this issue.

    I tried to find what is different to FunctionalTests HostDOCategoriesSwift with my bundle.

    • Build Settings
      • Always Embed Swift Standard Libraries
        • FunctionalTests is Yes
      • Enable Bitcode
        • FunctionalTests is No

    I fix these, but i can't resolve the issue...

    opened by jn000 20
  • Updating podspec to build pod from source

    Updating podspec to build pod from source

    Right now while integrating the pod into a project the only the framework gets downloaded, this makes it difficult to debug and find problems. Plus it also becomes difficult to use a custom version in your fork.

    Note: pod lib lint fails because the value of HEADER_SEARCH_PATHS is incorrect for development pods, a problem with CocoaPods while using development pod see CocoaPods issue

    type: enhancement cla: yes pr: address feedback 
    opened by tapthaker 19
  • grey_replaceText() add UITextViewNotification

    grey_replaceText() add UITextViewNotification

    add testReplaceTextOnUITextViewNotificationsPosted last request #642 force push ,so I can reopen it. Here is a new request. Sorry for that. @khandpur

    cla: no 
    opened by AzraelWang 18
  • Fix TrustKit swizzling issues in Earl Grey

    Fix TrustKit swizzling issues in Earl Grey

    As explained in #709, there is an issue with Earl Grey swizzling and proxy objects. This PR fixes specifically one of these issues when TrustKit is integrated in the host project and swizzles in TrustKit are enabled.

    The solution is to attempt getting the forwarding target class, if any, or use the actual class of the delegate as before.

    cla: yes 
    opened by LeoNatan 17
  • Fix all EarlGrey projects for Swift 3.0

    Fix all EarlGrey projects for Swift 3.0

    Fixes https://github.com/google/EarlGrey/issues/292.

    This is only done to fix the extant EarlGrey projects. As you can see, the EarlGrey syntax seems quite off. For this purpose, we plan to add a newer version of EarlGrey.swift that suits the Swift nomenclature better and tries to remove any unneeded wrappers.

    cla: yes pr: address feedback 
    opened by tirodkar 17
  • Add earlgrey_gem.yml & Fix rubocop

    Add earlgrey_gem.yml & Fix rubocop

    Update Ruby version requirement to 2.1 (Rubocop dropped 2.0). Both 2.0 and 2.1 are end of life Ruby versions.

    • https://www.ruby-lang.org/en/downloads/

    Fix #668

    cla: yes 
    opened by bootstraponline 16
  • Backport iOS 14 fixes to EarlGrey v1

    Backport iOS 14 fixes to EarlGrey v1

    This PR backports all the issues described in https://github.com/google/EarlGrey/issues/1357 to EarlGrey v1. Where possible I've cherry-picked the original commit:

    • XCTestCase::recordIssue support: https://github.com/google/EarlGrey/pull/1377
    • UITouch private API changes (based on @steipe approach published in https://github.com/google/EarlGrey/issues/1357)
    • Disable caret blink animation: https://github.com/google/EarlGrey/pull/1404/

    Additionally I've also backported/fixed other small issues:

    • Duplicate TextField id's: https://github.com/google/EarlGrey/pull/1391/
    • Remove duplicated/invalid file references from Build Phase
    • Explicitly remove support for arm64 simulator (Apple Silicon) (not supported by ochamcrest)
    • Configure indentation to match existing guidelines
    • Fix deprecated developmentRegion
    • Fix weird documentation error due to an escaped character

    Let me know if you want to add/remove/split anything.

    (I've signed the CLA)

    cla: yes 
    opened by xavierjurado 15
  • Failed to load module 'Helper Bundle' after running some test cases in EarlGrey2

    Failed to load module 'Helper Bundle' after running some test cases in EarlGrey2

    Hello, My Application crashed at the GREYHostApplicationDistantObject extension after running some test cases and got "Thread 1: EXC_BAD_ACCESS (code=2, address=0x7ff80d9f4ac8)". When I try to print "Bundle(for: (typeof:self))", I got

    warning: Swift error in scratch context: error: failed to load module 'Here is my Helper Bundle' . Shared Swift state for BizX Mobile has developed fatal errors and is being discarded. REPL definitions and persistent names/types will be lost. error: expression failed to parse: unknown error

    This crash repeats whenever I calls a instance method of a swift class which is inherited from a base class in another framework.

    Thanks.

    opened by EchoOOOO 0
  • [EarlGrey1]

    [EarlGrey1] "Failed to load the test bundle" error in Xcode 14

    Running EarlGrey1 tests against the iOS 13 Simulator is possible in Xcode 13 and older versions but not in Xcode 14.0, Xcode 14.1 and possibly newer versions of Xcode 14.

    Running EarlGrey1 tests in Xcode 14.0 and Xcode 14.1 results in the following error:

      Assertions: System: Failed to load the test bundle. If you believe this error represents a bug, please attach the result bundle at /Users/adilhussain/Library/Developer/Xcode/DerivedData/EarlGreyExperiment-dxfuddrtpdijnhhhmgkzxzvtmhad/Logs/Test/Test-EarlGreyExperiment-2022.11.01_08-37-29-+0000.xcresult. (Underlying Error: The bundle “EarlGreyExperimentTests” couldn’t be loaded because it is damaged or missing necessary resources. The bundle is damaged or missing necessary resources. Try reinstalling the bundle. dlopen_preflight(/Users/adilhussain/Library/Developer/CoreSimulator/Devices/67BA52C5-FF97-4A73-ABEB-4AE4718BDD82/data/Containers/Bundle/Application/7A233CF7-ECC2-42C9-9633-3AC76296F0C6/EarlGreyExperiment.app/PlugIns/EarlGreyExperimentTests.xctest/EarlGreyExperimentTests): Library not loaded: @rpath/XCTest.framework/XCTest
      Referenced from: /Users/adilhussain/Library/Developer/CoreSimulator/Devices/67BA52C5-FF97-4A73-ABEB-4AE4718BDD82/data/Containers/Bundle/Application/7A233CF7-ECC2-42C9-9633-3AC76296F0C6/EarlGreyExperiment.app/PlugIns/EarlGreyExperimentTests.xctest/Frameworks/EarlGrey.framework/EarlGrey
      Reason: Incompatible library version: EarlGrey requires version 1.0.0 or later, but XCTest provides version 0.0.0)
    

    You can see this error firsthand in this super simple Xcode workspace. The tests in this workspace run fine in Xcode 13 but not in Xcode 14.

    Note: I am aware that EarlGrey1 is deprecated. I am sharing this as a point of information for anyone like me who still has EarlGrey1 tests that they have not yet migrated away from EarlGrey1.

    opened by adil-hussain-84 0
  • Library not loaded: @rpath/AppFramework.framework/AppFramework

    Library not loaded: @rpath/AppFramework.framework/AppFramework

    Integration with Cocoapods,Xcode 14.0.1,EarlGrey 2.2.0,Compilation succeeded,But an error occurred at runtime: dyld[6772]: Library not loaded: @rpath/AppFramework.framework/AppFramework Referenced from: /private/var/containers/Bundle/Application/72BC7E92-E0CA-466E-AC3F-E7C198FF8BE4/TestCodeUp.app/TestCodeUp Reason: tried: '/private/var/containers/Bundle/Application/72BC7E92-E0CA-466E-AC3F-E7C198FF8BE4/TestCodeUp.app/Frameworks/AppFramework.framework/AppFramework' (mach-o file (/private/var/containers/Bundle/Application/72BC7E92-E0CA-466E-AC3F-E7C198FF8BE4/TestCodeUp.app/Frameworks/AppFramework.framework/AppFramework), but incompatible platform (have 'iOS-sim', need 'iOS')), '/private/var/containers/Bundle/Application/72BC7E92-E0CA-466E-AC3F-E7C198FF8BE4/TestCodeUp.app/Frameworks/AppFramework.framework/AppFramework' (mach-o file (/private/var/containers/Bundle/Application/72BC7E92-E0CA-466E-AC3F-E7C198FF8BE4/TestCodeUp.app/Frameworks/AppFramework.framework/AppFramework), but incompatible platform (have 'iOS-sim', need 'iOS')), '/private/var/containers/Bundle/Application/72BC7E92-E0CA-466E-AC3F-E7C198FF8BE4/TestCodeUp.app/Frameworks/AppFramework.framework/AppFramework' (mach-o file (/private/var/containers/Bundle/Application/72BC7E92-E0CA-466E-AC3F-E7C198FF8BE4/TestCodeUp.app/Frameworks/AppFramework.framework/AppFramework), but incompatible platform (have 'iOS-sim', need 'iOS')), '/private/var/containers/Bundle/Application/72BC7E92-E0CA-466E-AC3F-E7C198FF8BE4/TestCodeUp.app/Frameworks/AppFramework.framework/AppFramework' (mach-o file (/private/var/containers/Bundle/Application/72BC7E92-E0CA-466E-AC3F-E7C198FF8BE4/TestCodeUp.app/Frameworks/AppFramework.framework/AppFramework), but incompatible platform (have 'iOS-sim', need 'iOS')), '/private/var/containers/Bundle/Application/72BC7E92-E0CA-466E-AC3F-E7C198FF8BE4/TestCodeUp.app/Frameworks/AppFramework.framework/AppFramework' (mach-o file (/private/var/containers/Bundle/Application/72BC7E92-E0CA-466E-AC3F-E7C198FF8BE4/TestCodeUp.app/Frameworks/AppFramework.framework/AppFramework), but incompatible platform (have 'iOS-sim', need 'iOS')), '/private/var/containers/Bundle/Application/72BC7E92-E0CA-466E-AC3F-E7C198FF8BE4/TestCodeUp.app/Frameworks/AppFramework.framework/AppFramework' (mach-o file (/private/var/containers/Bundle/Application/72BC7E92-E0CA-466E-AC3F-E7C198FF8BE4/TestCodeUp.app/Frameworks/AppFramework.framework/AppFramework), but incompatible platform (have 'iOS-sim', need 'iOS')), '/private/preboot/Cryptexes/OS@rpath/AppFramework.framework/AppFramework' (errno=2), '/private/var/containers/Bundle/Application/72BC7E92-E0CA-466E-AC3F-E7C198FF8BE4/TestCodeUp.app/Frameworks/AppFramework.framework/AppFramework' (mach-o file (/private/var/containers/Bundle/Application/72BC7E92-E0CA-466E-AC3F-E7C198FF8BE4/TestCodeUp.app/Frameworks/AppFramework.framework/AppFramework), but incompatible platform (have 'iOS-sim', need 'iOS')), '/private/var/containers/Bundle/Application/72BC7E92-E0CA-466E-AC3F-E7C198FF8BE4/TestCodeUp.app/Frameworks/AppFramework.framework/AppFramework' (mach-o file (/private/var/containers/Bundle/Application/72BC7E92-E0CA-466E-AC3F-E7C198FF8BE4/TestCodeUp.app/Frameworks/AppFramework.framework/AppFramework), but incompatible platform (have 'iOS-sim', need 'iOS')), '/private/var/containers/Bundle/Application/72BC7E92-E0CA-466E-AC3F-E7C198FF8BE4/TestCodeUp.app/Frameworks/AppFramework.framework/AppFramework' (mach-o file (/private/var/containers/Bundle/Application/72BC7E92-E0CA-466E-AC3F-E7C198FF8BE4/TestCodeUp.app/Frameworks/AppFramework.framework/AppFramework), but incompatible platform (have 'iOS-sim', need 'iOS')), '/private/var/containers/Bundle/Application/72BC7E92-E0CA-466E-AC3F-E7C198FF8BE4/TestCodeUp.app/Frameworks/AppFramework.framework/AppFramework' (mach-o file (/private/var/containers/Bundle/Application/72BC7E92-E0CA-466E-AC3F-E7C198FF8BE4/TestCodeUp.app/Frameworks/AppFramework.framework/AppFramework), but incompatible platform (have 'iOS-sim', need 'iOS')), '/private/var/containers/Bundle/Application/72BC7E92-E0CA-466E-AC3F-E7C198FF8BE4/TestCodeUp.app/Frameworks/AppFramework.framework/AppFramework' (mach-o file (/private/var/containers/Bundle/Application/72BC7E92-E0CA-466E-AC3F-E7C198FF8BE4/TestCodeUp.app/Frameworks/AppFramework.framework/AppFramework), but incompatible platform (have 'iOS-sim', need 'iOS')), '/private/var/containers/Bundle/Application/72BC7E92-E0CA-466E-AC3F-E7C198FF8BE4/TestCodeUp.app/Frameworks/AppFramework.framework/AppFramework' (mach-o file (/private/var/containers/Bundle/Application/72BC7E92-E0CA-466E-AC3F-E7C198FF8BE4/TestCodeUp.app/Frameworks/AppFramework.framework/AppFramework), but incompatible platform (have 'iOS-sim', need 'iOS')), '/System/Library/Frameworks/AppFramework.framework/AppFramework' (errno=2, not in dyld cache) Library not loaded: @rpath/AppFramework.framework/AppFramework Referenced from: /private/var/containers/Bundle/Application/72BC7E92-E0CA-466E-AC3F-E7C198FF8BE4/TestCodeUp.app/TestCodeUp Reason: tried: '/private/var/containers/Bundle/Application/72BC7E92-E0CA-466E-AC3F-E7C198FF8BE4/TestCodeUp.app/Frameworks/AppFramework.framework/AppFramework' (mach-o file (/private/var/containers/Bundle/Application/72BC7E92-E0CA-466E-AC3F-E7C198FF8BE4/TestCodeUp.app/Frameworks/AppFramework.framework/AppFramework), but incompatible platform (have 'iOS-sim', need 'iOS')), '/private/var/containers/Bundle/Application/72BC7E92-E0CA-466E-AC3F-E7C198FF8BE4/TestCodeUp.app/Frameworks/AppFramework.framework/AppFramework' (mach-o file (/private/var/containers/Bundle/Application/72BC7E92-E0CA-466E-AC3F-E7C198FF8BE4/TestCodeUp.app/Frameworks/AppFramework.framework/AppFramework), but incompatible platform (have 'iOS-sim', need 'iOS')), '/private/var/containers/Bundle/Application/72BC7E92-E0CA-466 dyld config: DYLD_INSERT_LIBRARIES=@executable_path/Frameworks/AppFramework.framework/AppFramework:/usr/lib/libMainThreadChecker.dylib

    Excuse me, how to solve this problem?

    opened by lanseqiaokeli 0
  • [EarlGrey2] AppFramework does not build - 'GREYUILibUtils.h' file not found

    [EarlGrey2] AppFramework does not build - 'GREYUILibUtils.h' file not found

    It looks like the AppFramework does not build after this commit: https://github.com/google/EarlGrey/commit/8a4af43838f33b0d61b2da5334957b2983fe00a3

    Repro steps:

    1. Clone a fresh EarlGrey2 instance from the repo using the given steps:
    // Clone EarlGrey 2.0
    git clone -b earlgrey2 https://github.com/google/EarlGrey.git
    
    // Download any dependencies
    sh Scripts/download_deps.sh
    
    1. Open the xcodeproj in Xcode 14 (also repros in Xcode 13)
    2. Select "AppFramework" as the build target, kickoff build with 'Cmd + B'

    The build immediately fails with: 'GREYUILibUtils.h' file not found

    The previous commit does not run into this issue: https://github.com/google/EarlGrey/commit/4e3e67586cb1cba8aa317f446ca3d367ec8f618b

    AppFramework_BuildFailure ExampleFailure
    opened by brocklyons 2
  • Support viewForRow in grey_pickerColumnSetToValue matcher

    Support viewForRow in grey_pickerColumnSetToValue matcher

    Matcher grey_pickerColumnSetToValue works fine for UIPicker with delegate that implements

    • pickerView:titleForRow:forComponent OR
    • pickerView:attributedTitleForRow:forComponent

    but currently does not work for pickerView:viewForRow:forComponent:reusingView:

    I believe it should work with viewForRow, because GREYPickerAction works fine with it and there even test that checks it – PickerViewInteractionTest.testViewForRowDefined.

    Unfortunately, I think that this test is broken: corresponding PickerViewController implements both delegate methods – pickerView:titleForRow:forComponent AND pickerView:viewForRow:forComponent:reusingView:, that why test pass.

    So, I added support for viewForRow in grey_pickerColumnSetToValue matcher, its just copy-paste from GREYPickerAction and updated test code.

    opened by MontakOleg 4
Releases(2.2.2)
  • 2.2.2(Jun 7, 2022)

    2.2.2 (06/3/2022)

    Baseline: [a430608]
    + [a430608]: Update AppStateTracker logs.
    

    Enhancements

    • Sanitizers are now supported with EarlGrey.
    • Test-side screenshots are generated for a test failure.
    • WKWebView has an idling resource added for it.
    • Improved logging with GREYLogger for debugging.
    • Some cursory support has been added for matching SwiftUI views.

    Bug fixes

    • Multiple fixes for iOS 15 related to scrolling, window synchronization etc.

    Compatibility

    • EarlGrey has been tested for working till Xcode version 13.4 and Swift 5.

    Known Issues

    • EarlGrey does not track recurrent animations and will timeout for infinite animations in dequeued cells.
    Source code(tar.gz)
    Source code(zip)
    EarlGreyApp.zip(1.12 MB)
  • 2.2.1(Dec 11, 2020)

    2.2.1 (12/9/2020)

    Baseline: [91dc49f]
    + [91dc49f]: Move test-side screenshot to XCUIScreen.
    

    Enhancements

    • Improved synchronization by performing most of the GREYActions on the main thread right after matching.
    • Improved synchronization by tracking all NSTimers added in the main thread.
    • Added EarlGrey API so that users can choose the root matcher for subsequent interactions.
    • Verbose logging can be added through NSUserDefaults.
    • iOS 14 support has been added for location alert strings.
    • Dedupe superview/subview pair if accessibility attributes are the same as this is a valid case.

    Bug fixes

    • Fix scrolling synchronization issue where tapping was failing at the end of scroll action.
    • Fix crash when GREYConfiguration methods were called before relaunching the application.
    • Fix crash when error screenshot was taken on the test side.

    Compatibility

    • EarlGrey has been tested for working till Xcode version 12.2 and Swift 5.

    Known Issues

    • There are animation issues with Context Menu’s and multi-window animations.
    • ASAN, UBSAN and TSAN do not work with EarlGrey at the moment.
    Source code(tar.gz)
    Source code(zip)
    EarlGreyApp.zip(1.68 MB)
  • 2.2.0(Oct 20, 2020)

    2.2.0 (10/16/2020)

    Baseline: [ddf2911]
    + [ddf2911]: GREYCAAnimationDelegate optimization.
    

    Enhancements

    • Support has been added for Xcode 11, 12 and iOS 13.x, iOS 14.
    • Performance improvement for visibility checker that is used for grey_tap(), grey_sufficientlyVisible(), etc.
    • Error logs are now more concise and clear.
    • Miscellaneous synchronization improvements related to scroll views, timers and network tracking.
    • All EarlGrey interactions from the test side now work on a separate background queue.
    • Added app-under-test crash handler API to bring back crashed app and continue remaining test cases properly.
    • Added dispatch policy API and the new background execution policy, which is more resistant to remote call related deadlock.

    Bug Fixes

    • UIView and UIViewController owned by test can no longer be sent to app-under-test by remote invocation, which is considered a common mistake.

    Compatibility

    • EarlGrey has been tested for working till Xcode version 12.2 and Swift 5.

    Known Issues

    • There are animation issues with Context Menu’s and multi-window animations.
    • ASAN, UBSAN and TSAN do not work with EarlGrey at the moment.
    Source code(tar.gz)
    Source code(zip)
    EarlGreyApp.zip(3.34 MB)
  • 1.16.0(Nov 4, 2019)

  • 2.0.0(Aug 5, 2019)

  • 2.0.0-rc(Jun 27, 2019)

  • 1.15.1(May 18, 2019)

    1.15.1 (05/17/2019)

    Baseline: [b15a131]
    + [b15a131]: Fix TrustKit swizzling issues in Earl Grey
    

    Bug Fixes

    • Accessibility fix added for device tests on 12.1.
    • Fix TrustKit swizzling with proxy delegates for NSURlSession.
    • Fixed Swift 5.0 wrappers.

    Compatibility

    • EarlGrey has now been tested for working till Xcode version 10.1 and Swift 5.
    Source code(tar.gz)
    Source code(zip)
    EarlGrey.zip(2.05 MB)
  • 1.15.0(Aug 3, 2018)

    Change Log

    1.15.0 (08/03/2018)

    Baseline: [59ce3b6c]
    + [59ce3b6c]: Fix default Swift version in EarlGreyExampleSwiftTests xcode project
    

    Enhancements

    • Added support for accessibility in iOS 12.
    • Updated the visibility checker to support keyboards in iOS 12.
    • Updated Analytics Configurations.
    • Fixed Formatting Issues.
    • Updated invalid api and compatibility docs.

    Compatibility

    • EarlGrey has now been tested for working till Xcode version 10.0 beta 2.
    • Some of the internal unit tests break on Xcode 9.3+ due to change in exception name thrown by XCTest. Those are still being investigated.
    Source code(tar.gz)
    Source code(zip)
    EarlGrey.zip(2.10 MB)
  • 1.14.0(Jun 6, 2018)

    Change Log

    Details changes in each release of EarlGrey. EarlGrey follows semantic versioning.

    1.14.0 (06/06/2018)

    Baseline: [c201f58]
    + [c201f58]: Fix default Swift version in EarlGreyExampleSwiftTests xcode project
    

    Enhancements

    • Add Swift 4 support in the gem.
    • Update block declarations to support strict prototypes.
    • Add support for PDF display for UIWebViewIdlingResource.
    • Remove Swift 2 in the gem since Xcode 7.x is not supported anymore.

    Bug Fixes

    • Fix FTRLocalUIWebViewTest by updating testAJAXLoad to detect proper web view elements.

    Compatibility

    • EarlGrey has now been tested for working till Xcode version 9.4. Any small test breakages with Xcode 9.4 are being tested.

    Contributors

    Thanks to adam-b and keefertaylor!

    Source code(tar.gz)
    Source code(zip)
    EarlGrey.zip(2.10 MB)
  • 1.13.0(Apr 5, 2018)

    Change Log

    Details changes in each release of EarlGrey. EarlGrey follows semantic versioning.

    1.13.0 (04/03/2018)

    Baseline: [2b3939a]
    + [2b3939a]: Fix Swift file issues with the updated EarlGrey code for release 1.13.0
    

    Enhancements

    • Add nullability to EarlGrey Headers. Issue #449
    • Remove notNil method and add explicit check in the matcher itself.
    • Update the Swift wrapper to used refined methods to prevent discardable result warnings.
    • Update EarlGrey assert(with:) calls to assert(_:).
    • Move the GREYRunLoopSpinner to spin on the thread passed to it instead of the main thread.
    • Add tests for disabled buttons, fix visibility test and add iOS 11 support to tests.
    • Move EarlGreyImpl interface out of EarlGrey.h.
    • Add shake motion support to EarlGrey.

    Bug Fixes

    • Use TIPreferencesController to change the keyboard settings so it will not load TIUserWordsManager, which can cause occasional crashes on iOS 11.0+.
    • Tell the preferences not to show keyboard tutorial as it interferes with typing.
    • Close MVC unconditionally to prevent erroneous scenarios where it fails to execute the completion block, leaving it resident on the screen forever.

    Compatibility

    • EarlGrey has now been tested for working till Xcode version 9.3. Any small test breakages with Xcode 9.3 are being tested.
    Source code(tar.gz)
    Source code(zip)
    EarlGrey.zip(2.10 MB)
  • 1.12.1(Sep 1, 2017)

  • 1.12.0(Aug 29, 2017)

    Change Log

    Details changes in each release of EarlGrey. EarlGrey follows semantic versioning.

    1.12.0 (08/22/2017)

    Baseline: [ae61a45]
    + [ae61a45]: Fix Main thread violation: UIView setHidden called from non-main thread.
    

    Enhancements

    • More robust synchronization with NSURLSession. This fixes many flakiness seen with EarlGrey not waiting for the completion of callback methods after network response has been received.
    • Performance improvements in GREYAppStateTracker. It uses a deallocation tracker in place of NSString to free up memory sooner.
    • Fallback to EarlGrey.swift v3 when gem cannot find the correct file for the current swift version.
    • Added -Wdocumentation for all EarlGrey projects.
    • Use static constructor in place of initialize method for one-time setup.
    • Remove extra parentheses added around failed assertion expressions.
    • Updated error messages on failure of layout contraints.
    • Improved Visibility checker's shifted pixel image redraw logic.

    Bug Fixes

    • Fixed floating point issue in layout constraint matchers. Issue #594
    • Fixed an issue where an exception is thrown when -[UIWebDocumentView text] is called in the middle of loading.
    • Fixed a bug in isKeyboardShown with zero sized input accessory views.
    • Fixed CGAffineTransformInvert: singular matrix message that appears during Pinch tests.

    Compatibility

    • EarlGrey now supports Xcode version 9.0 up to 9.0 beta 6. All EarlGrey project tests pass with these versions.
    Source code(tar.gz)
    Source code(zip)
    EarlGrey.zip(2.03 MB)
  • 1.11.0(Jul 22, 2017)

    1.11.0 (07/21/2017)

    Baseline: [0d1086d]
    + [0d1086d]: Modify 1.10.2 -> 1.11.0 and update the CHANGELOG
    

    Enhancements

    • Added support for iOS 11 & Xcode 9.0.
    • Added the grey_textFieldValue() matcher for updates to UITextFields with iOS11.

    Bug Fixes

    • Fixed Minor issue that was causing infinitely long touch paths for zero sized areas.
    • Grammatical and Language Fixes.
    • Refactored FunctionalTests tests for adding iOS 11 support.
    Source code(tar.gz)
    Source code(zip)
    EarlGrey.zip(2.01 MB)
  • 1.10.1(Jul 14, 2017)

    1.10.1 (07/14/2017)

    Baseline: [2abda72]                                                                                  
    + [2abda72]: Modified GREYElementInteraction.m to drain the thread for a timeout.                    
    

    Enhancements

    • Improved GREYAssert macros to not wait until idle as it can cause it to never return.
    • Improved Search action to not wait until idle as it can cause it to never return.
    Source code(tar.gz)
    Source code(zip)
    EarlGrey.zip(2.14 MB)
  • 1.10.0(Jul 6, 2017)

    1.10.0 (07/05/2017)

    Baseline: [a386cb2]
    + [a386cb2]: Update Changelog for the 1.10.0 release for the Screenshot Docs change.
    

    Bug Fixes

    • Resolved visibility checker overlapping view issue. Issue #532
    • Use accessibility ID in place of accessibility label for keyboard modifier keys. Issue #539

    Enhancements

    • Removed kGREYConfigKeyScreenshotDirLocation in favor of kGREYConfigKeyArtifactsDirLocation.
    • Fixed all issues reported by Xcode's static analysis.
    • Fixed long press test failures on travis.
    • Improved interaction error logging by adding more information about failure to the out error parameter.
    • Added more error details to timeout failures.
    • Add explicit 1st and 2nd param to grey_allOf and grey_anyOf to prevent redundant uses.
    • Update jazzy copyright year.

    Compatibility

    • Adding xcode version to backwards compatibility doc.
    Source code(tar.gz)
    Source code(zip)
    EarlGrey.zip(1.98 MB)
  • 1.9.4(Jun 10, 2017)

    1.9.4 (06/09/2017)

    Baseline: [ed9c6d3]
    + [ed9c6d3]: Add RVM before-install step in before install for travis runs.
    

    Bug Fixes

    • Fixed a bug in scroll action that can sometimes cause a tap at the end of scroll.

    Enhancements

    • Improved CI execution on travis.
    • Updated test app with better AutoLayout support.
    • Improved docs for earlgrey gem, contributors guide etc.
    • Fixed all asserts to use internal implementation instead of NSAssert which can be disabled.
    • Updated cheatsheet render script to use Chrome 59.

    Contributors

    Source code(tar.gz)
    Source code(zip)
    EarlGrey.zip(2.13 MB)
  • 1.9.3(May 27, 2017)

    1.9.3 (05/26/2017)

    Baseline: [a915cd1]
    + [a915cd1]: Fix breaking test with Long Press
    

    Improvements

    • Revaming of Swipe Touch Path Gestures to make them more like a real-user.

    Bug Fixes

    • Fixed breaking tests for Long Press Gestures.
    • Fix source_tree and relative path for the EarlGrey gem to prevent Carthage breakages.
    Source code(tar.gz)
    Source code(zip)
    EarlGrey.zip(2.06 MB)
  • 1.9.2(Apr 21, 2017)

    1.9.2 (04/21/2017)

    Baseline: [b9d7a7c]
       + [b9d7a7c]: Update OS=10.3 for travis CI
    

    Bug Fixes

    • Fixed timeout related failures from being reported as assertion failures.
    • Fixed to wait for rotation to complete before verifying that it changed.
    • Fixed Swift breaks by correcting issue with Gem adding EarlGrey.swift for Objective C targets.
    • Fixed race condition with reading and writing to state tracker elementID.
    Source code(tar.gz)
    Source code(zip)
    EarlGrey.zip(2.14 MB)
  • 1.9.1(Apr 14, 2017)

    1.9.1 (04/14/2017)

    Baseline: [932c3f6]
       + [932c3f6]: Doc updates
    

    Bug Fixes

    • Fixed a bug in interaction point calculation for cases where activation point and the center of visible area is hidden.

    Enhancements

    • Updated documentation for GREYCondition and ruby setup.
    • Minor improvements to formatting of failure messages.
    • Updated travis to run tests on iOS 10.3 and Xcode 8.3.
    • Deleted .arcconfig file.

    Contributors

    Source code(tar.gz)
    Source code(zip)
    EarlGrey.zip(2.13 MB)
  • 1.9.0(Apr 1, 2017)

    1.9.0 (03/31/2017)

    Baseline: [6bceffc]
       + [6bceffc]: Sync 1.9.0
    

    Compatibility

    • Requires iOS 8 as the minimum deployment target.
    • Supports Xcode 8.3 and iOS 10.3 on devices and simulators.
    • The EarlGrey gem runs out of the box for Swift 3.0 and Swift 2.3.

    New Features

    • Added -[GREYKeyboard dismissKeyboardWithError:] API to dismiss the keyboard.

    Enhancements

    • Improved earlgrey gem by removing post_install and letting pod update the project.
    • Improved swift support for grey_allOf and grey_anyOf.
    • Several documentation updates including installation steps improvements.
    • Added gem badge to README.md.

    Contributors

    Source code(tar.gz)
    Source code(zip)
    EarlGrey.zip(1.99 MB)
  • 1.8.0(Mar 18, 2017)

    1.8.0 (03/17/2017)

    Baseline: [0dc7c18]
       + [0dc7c18]: 1.8.0 Release
    

    New Features

    • Added multi-finger swipe action API's:
      • grey_multiFingerSwipeFastInDirection
      • grey_multiFingerSwipeSlowInDirection
      • grey_multiFingerSwipeFastInDirectionWithStartPoint
      • grey_multiFingerSwipeSlowInDirectionWithStartPoint

    Bug Fixes

    • Fixed issue with accessibility spamming "Remote service does not respond to _accessibilityMachPort" message on iOS 9.1 device.
    • Fixed issues with EarlGrey working with a UIAccessibilityTextFieldElement.
    • Fixed typing by blacklisting UICompatibilityInputViewController in UIViewController tracking.

    Compatibility

    • Requires iOS 8 as the minimum deployment target.
    • Supports Xcode 8.3 beta 4 and iOS 10.3 on devices and simulators.
    • The EarlGrey gem runs out of the box for Swift 3.0 and Swift 2.3.

    Enhancements

    • Improvements to the EarlGrey FunctionalTests TestRig.
    • All GREYAssertXXX macros now wait for the app to idle before being evaluated.
    • Unified the Copy Files modification script for Carthage and CocoaPods support.

    Contributors

    bootstraponline petaren

    Source code(tar.gz)
    Source code(zip)
    EarlGrey.zip(2.04 MB)
  • 1.7.2(Feb 18, 2017)

    1.7.2 (02/17/2017)

    Baseline: [6d55af5]
       + [6d55af5]: 1.7.2 Release
    

    Bug Fixes

    • Fixed Swizzler to properly reset swizzled selectors.
    • Fixed typing by blacklisting UICompatibilityInputViewController in UIViewController tracking.

    Compatibility

    • Requires iOS 8 as the minimum deployment target.
    • Supports Xcode 8.2.1 and iOS 10.2.1 on devices and simulators.
    • The EarlGrey gem runs out of the box for Swift 3.0 and Swift 2.3.

    Enhancements

    • Updated analytics to use an client ID instead of user ID.

    Contributors

    mbaxley, thank you!

    Source code(tar.gz)
    Source code(zip)
    EarlGrey.zip(1.97 MB)
  • 1.7.1(Feb 4, 2017)

    1.7.1 (02/03/2017)

    Baseline: [e026773]
    + [e026773]: Change version numbers for EarlGrey 1.7.1
    

    Bug Fixes

    • Fixed an issue with constraint failure details not being logged in the error trace.
    • Updated nullability for GREYMatchers to improve Swift support.
    • Minor changes to logging strings and docs.

    Compatibility

    • Requires iOS 8 as the minimum deployment target.
    • Supports Xcode 8.2.1 and iOS 10.2.1 on devices and simulators.
    • The EarlGrey gem runs out of the box for Swift 3.0 and Swift 2.3.

    Enhancements

    • Updated analytics to use an md5 hashed uid.
    Source code(tar.gz)
    Source code(zip)
    EarlGrey.zip(2.12 MB)
  • 1.7.0(Jan 26, 2017)

    1.7.0 (01/25/2017)

    Baseline: [0768a62]
    + [0768a62]: Using custom text matcher instead of hasProperty matcher
    

    Bug Fixes

    • Fixed a flake in testTrackingZombieQueue.
    • Fixed CGRectIntegralInside to handle negative rectangles.
    • Improved memory handling by moving autorelease pool inside loops.
    • Fixed the bundle id to be consistent across all the test projects.
    • Minor CI and other bug fixes.

    Compatibility

    • Requires iOS 8 as the minimum deployment target.
    • Supports with Xcode 8.2.1 and iOS 10.2.1 on devices and simulators.

    New Features

    • Updated analytics to include hash of test class name and hash of test case names to better estimate the volume of EarlGrey usage.
    • Updated the readme to explain these changes.
    • Updated tests for analytics to test new features.

    Enhancements

    • Improved EarlGrey error logging for better post processing Issue #392.
    • Removed the deprecated methods and cleaned up private headers.
    • The EarlGrey gem runs out of the box for Swift 3.0 and Swift 2.3.

    Deprecations

    • Removed deprecated methods grey_pinchFastInDirection and grey_pinchSlowInDirection in favor of grey_pinchFastInDirectionAndAngle and grey_pinchSlowInDirectionAndAngle respectively.

    Contributors

    bootstraponline, stkhapugin and kebernet

    Source code(tar.gz)
    Source code(zip)
    EarlGrey.zip(2.11 MB)
  • 1.6.2(Jan 7, 2017)

    1.6.2 (01/06/2017)

    Baseline: [0cdda9c]
    + [0cdda9c]: EarlGrey Sync for 1.6.2
    

    Bug Fixes

    • Updated the EarlGrey API for Swift 3.0 as per the latest guidelines.
    • Improved web tests to work with current google.com UI.
    • Fixed a bug in the visibility checker for 32bit platform.
    • Fixed flakiness caused by NSDate issues in EarlGreyExampleSwiftTests.

    Enhancements

    • Added a travis hook to stop CI runs for docs-only changes.

    Contributors

    Thanks to bootstraponline and the rest of the contributors!

    Source code(tar.gz)
    Source code(zip)
    EarlGrey.zip(1.82 MB)
  • 1.6.1(Dec 20, 2016)

  • 1.6.0(Dec 8, 2016)

    Baseline: [5080a21]
       + [5080a21]: Updated changelog info.plist pod spec and gem version for 1.6.0 release.
    

    Compatibility

    • Requires iOS 8 as the minimum deployment target.
    • The EarlGrey gem runs out of the box for Swift 3.0 and Swift 2.3.
    • Has been tested for support till iOS 10.1 on devices and simulator.

    Bug Fixes

    • Fixed CocoaPods issue with using EarlGrey as a module in Swift projects.
    • Fixed issue with Accessibility service not enabled for simulators and devices.
    • Minor documentation and syntax fixes.

    Enhancements

    • Moved failure handler from a global variable to a thread local storage, like NSAssertionHandlers.
    • Exposed the angle for pinch action in GREYPinchAction.
    • Added EarlGreyExample CocoaPods project to travis.

    Deprecations

    • Deprecated grey_pinchSlowInDirection and grey_pinchFastInDirection in favor of grey_pinchFastInDirectionAndAngle and grey_pinchSlowInDirectionAndAngle.
    Source code(tar.gz)
    Source code(zip)
    EarlGrey.zip(2.00 MB)
  • 1.5.3(Nov 13, 2016)

  • 1.5.2(Nov 16, 2016)

    Baseline: [f3ee931]
       + [f3ee931]: Updated ChangeLog and pod spec for 1.5.2 release
    

    Compatibility

    • Handle bit-dependent CGFloat with bit-dependent trig function

    Enhancements

    • Enhance precision of timer used for touch injection
    • Removed requirement for bridging header for Swift and EarlGrey
    Source code(tar.gz)
    Source code(zip)
    EarlGrey.zip(1.75 MB)
  • 1.5.1(Nov 8, 2016)

    Baseline: [d9eb1bc]
       + [d9eb1bc]: Updated ChangeLog and pod spec for 1.5.1 release
    

    Compatibility

    • Requires iOS 8 as the minimum deployment target.
    • The EarlGrey gem runs out of the box for Swift 3.0 and Swift 2.3.
    • Has been tested for support till iOS 10.01 on devices and simulator.

    Bug Fixes

    • Fixed CI Ruby test for Carthage.

    Enhancements

    • Improved touch injection speed by making it work independent of the screen refresh rate.
    • Added synchronization for NSURLConnection::sendSynchronousRequest.
    • Exclude URLs that start with data scheme from being synchronized.
    • Updated grey_clearText action to accept elements conforming to UITextInput protocol.
    Source code(tar.gz)
    Source code(zip)
    EarlGrey.zip(1.45 MB)
Owner
Google
Google ❤️ Open Source
Google
Kfm-ios-test - Test online for iOS Developer position in Kimia Farma or PT. Buana Varia Komputama

kfm-ios-test Kimia Farma Mobile iOS Test Test online for iOS Developer position

Erwindo Sianipar 3 Feb 23, 2022
Test-To-Do-List - Test To Do List with core data

test-To-Do-List This is my first pet project with core data Launch screen Main s

Artem 0 Feb 26, 2022
BDD Framework and test runner for Swift projects and playgrounds

Spectre Special Executive for Command-line Test Running and Execution. A behavior-driven development (BDD) framework and test runner for Swift project

Kyle Fuller 392 Jan 1, 2023
test ios UnitTest and UITest

github_actions Bundlerの導入 fastlaneやiOSパッケージマネージャであるCocoaPodsはRubyのライブラリ 開発チームで使用するバージョンを揃えるためにBundlerを導入する bundlerのインストール gem install bundler Gemfile

SUGY 0 Nov 3, 2021
iOS Test Hasitha

Welcome to the Bidone iOS Coding Test! iOS Create a simple application with the list of orders from viewModel and display them in a list. When a user

null 0 Nov 12, 2021
iOS Test for Openbank by David Moreno Lora

MarvelMobileTest-iOS iOS Test for Openbank by David Moreno Lora Installation Clone the project and install the dependencies using pod install Once th

David Moreno Lora 0 Nov 16, 2021
A collection of useful test helpers designed to ease the burden of writing tests for iOS applications.

MetovaTestKit is a collection of useful test helpers designed to ease the burden of writing tests for iOS applications. Requirements Installation Usag

null 23 Aug 29, 2021
Alef Dev Test iOS

AlefDev тестовое задание iOS Задача Разработайте экран, где человек может заполн

null 0 Feb 25, 2022
Rapptr iOS Test Jimin Kim

Hello! Your task is to use the provided project to create the iOS app displayed

null 0 Dec 22, 2021
Mooviely - Mooviely Basic App for IOS Test

Mooviely Mooviely Basic App for IOS Test. Anasayfa Bu sayfa açıldığında ekranın

null 0 Feb 13, 2022
Monkey Test Tool For iOS

CrashMonkey Japanese About This is a tool of monkey test(random operation test) for iOS applications. Please watch the demo movie. CrashMonkey uses UI

Ken Morishita 198 May 25, 2022
Stub your network requests easily! Test your apps with fake network data and custom response time, response code and headers!

OHHTTPStubs OHHTTPStubs is a library designed to stub your network requests very easily. It can help you: test your apps with fake network data (stubb

Olivier Halligon 4.9k Dec 29, 2022
The XCTest Project, A Swift core library for providing unit test support

XCTest The XCTest library is designed to provide a common framework for writing unit tests in Swift, for Swift packages and applications. This version

Apple 1k Jan 4, 2023
Test Library for Swift's Error Handling

CatchingFire CatchingFire is a Swift test framework, which helps making expectations against the error handling of your code. It provides for this pur

Marius Rackwitz 75 May 16, 2022
This repository accompanies Test-Driven Development in Swift: Compile Better Code with XCTest and TDD

Apress Source Code This repository accompanies Test-Driven Development in Swift: Compile Better Code with XCTest and TDD by Gio Lodi (Apress, 2021). D

Apress 57 Jan 1, 2023
This is a simple test app getting data from network to practice a tad bit.

test This is a simple test app getting data from network to practice a tad bit. Start Nothing fancy, no CocoaPods, just clone and run! Architecture Ju

null 1 Oct 9, 2021
Test case project for mackolik

Mackolik - iOS Developer - Test Case Gökhan Mandacı 28 Oct 2021 I developed a two-page app and a general purpose drop down widget for the Mackolik Tes

Gökhan Mandacı 0 Oct 28, 2021
This repo holds the code for Dubizzle & Bayut test App

DubizzleClassified This repo holds the code for Dubizzle & Bayut test App About App This is a simple app which basically fetches item list from the gi

Ghassan 0 Jun 2, 2022
Test task application based on Swift using CoreData, Alamofire, AlamofireImage and CocoaPods

iTunes Search Test task application based on Swift using CoreData, Alamofire, AlamofireImage and CocoaPods Features ?? Searching music albums by name

Alexander Zhukov 0 Oct 31, 2021