iOS UI automation tests helper framework, designed to work with the AutoMate
Switch branches/tags
Nothing to show
Clone or download
Latest commit a6601a7 Oct 21, 2018
Permalink
Type Name Latest commit message Commit time
Failed to load latest commit information.
AutoMate-AppBuddy.xcodeproj Update required files for release, bump version to 1.4.0. Oct 21, 2018
AutoMate-AppBuddy Regenerate documentation, add missing docs. Oct 21, 2018
AutoMate-AppBuddyTests Set newest Ruby and Swift versions. Update configuration files with n… Oct 20, 2018
assets PAI-87 Add LICENSE, README, podspec, Travis, Jenkins and Fastlane con… Feb 24, 2017
docs Regenerate documentation, add missing docs. Oct 21, 2018
fastlane Configured project to use one target Jan 10, 2018
.gitignore Added documentation Apr 6, 2017
.jazzy.yaml PAI-97 Add "Application Is Running Inside a UI Test Environment" Jun 29, 2017
.ruby-version Set newest Ruby and Swift versions. Update configuration files with n… Oct 20, 2018
.swift-version Set newest Ruby and Swift versions. Update configuration files with n… Oct 20, 2018
.swiftlint.yml PAI-57 Add contacts with ContactFramework Feb 22, 2017
.travis.yml Set newest Ruby and Swift versions. Update configuration files with n… Oct 20, 2018
AutoMate-AppBuddy.podspec Update required files for release, bump version to 1.4.0. Oct 21, 2018
Changelog.md Update required files for release, bump version to 1.4.0. Oct 21, 2018
Dangerfile PAI-124 Improve Jenkinsfile for GitHub Jun 26, 2017
Gemfile Fix cocoapods validation according to CocoaPods/CocoaPods#8089 Oct 21, 2018
Gemfile.lock Fix cocoapods validation according to CocoaPods/CocoaPods#8089 Oct 21, 2018
Jenkinsfile Set newest Ruby and Swift versions. Update configuration files with n… Oct 20, 2018
LICENSE PAI-87 Add LICENSE, README, podspec, Travis, Jenkins and Fastlane con… Feb 24, 2017
Makefile Updated documentation Nov 14, 2017
README.md Set newest Ruby and Swift versions. Update configuration files with n… Oct 20, 2018

README.md

AutoMate, made by PGS Software

AutoMateAppBuddyTemplatesModelGenie

AutoMate AppBuddy

AppBuddy is a helper framework for UI automation tests, designed to work with the AutoMate. It can disable animations in the application and manage events, reminders and contacts.

Swift 4.2 Travis CocoaPods Compatible Documentation Carthage Compatible Platform License

Installation

The most convenient way to install it is by using CocoaPods with Podfile:

pod 'AutoMate-AppBuddy'

or using Carthage and add a line to Cartfile.private:

github "PGSSoft/AutoMate-AppBuddy"

Cartfile.private should be used because AutoMate framework will be used by UI Tests target only not by the tested application.

Note

AppBuddy should be linked with target application, not with the test target.

Usage

Full documentation is available at https://pgssoft.github.io/AutoMate-AppBuddy/.

  1. Duplicate existing application target.

  2. Import AutoMate_AppBuddy framework to app delegate.

    import AutoMate_AppBuddy
  3. Setup LaunchEnvironmentManager in application(_:didFinishLaunchingWithOptions:).

    let launchEnvironmentManager = LaunchEnvironmentManager()
    launchEnvironmentManager.add(handler: defaultEventKitHander, for: .events)
    launchEnvironmentManager.add(handler: defaultEventKitHander, for: .reminders)
    launchEnvironmentManager.add(handler: defaultContactsHander, for: .contacts)
    launchEnvironmentManager.add(handler: defaultIsInUITestHandler, for: .isInUITest)
    launchEnvironmentManager.add(handler: AnimationHandler(), for: .animation)
    launchEnvironmentManager.setup()

Features (or ToDo)

  • Disable UIView animations
  • Managing events, reminders and contacts
  • Two way communication
  • Stubbing network requests
  • Stubbing contacts, events and reminders
  • Stubbing notifications
  • Taking screenshots
  • Clearing application data
  • Simulating push notifications

Example application

AutoMate repository contains example application under AutoMateExample directory. Structure of the application is simple, but the project contains extensive suite of UI tests to showcase capabilities of the library.

Development

Full documentation is available at https://pgssoft.github.io/AutoMate-AppBuddy/.

If you want to handle your custom launch environments, you have to implement Handler protocol, e.g.

struct CustomHandler: Handler {
    func handle(key: String, value: String) {
        if value == "production" {

        }
    }
}

launchEnvironmentManager.add(handler: CustomHandler(), for: "SERVER")

Contributing

Bug reports and pull requests are welcome on GitHub at https://github.com/PGSSoft/AutoMate-AppBuddy.

License

The project is available as open source under the terms of the MIT License.

About

The project maintained by software development agency PGS Software. See our other open-source projects or contact us to develop your product.

Follow us

Twitter URL
Twitter Follow