Tech Talk #5 : KIF-iOS Integration Testing Framework - Nguy»…n Hi»‡p

download Tech Talk #5 : KIF-iOS Integration Testing Framework - Nguy»…n Hi»‡p

of 12

  • date post

  • Category


  • view

  • download


Embed Size (px)

Transcript of Tech Talk #5 : KIF-iOS Integration Testing Framework - Nguy»…n Hi»‡p

  • KIF-iOS Integration Testing Framework

    How to do iOS UI testing with KIF

  • Whats KIF?KIF, which stands for Keep It Functional, is an iOS integration test framework.

    KIF builds and performs the tests using a standard XCTest testing target.

    It allows for easy automation of iOS apps by leveraging the Accessibility APIs in iOS. Youll be able to write tests that simulate user input, like touches, swipes, text entry and more.

  • FeaturesMinimizes Indirection : written in Objective-C, minimizing the number of layers you have to build.

    Easy Configuration: integrates directly into Xcode project.

    Wide OS coverage: iOS 5.1 and above.

    Test Like a User: KIF attempts to imitate actual user input.

    Automatic Integration with Xcode Testing Tools: same testing platform (subclass of XCTestCase), easily run a single KIF test with the Test Navigator

  • Other options?1. XCTest2. UI Automation3. Calabash4. FRANK BDD for iOS5. Specta, Kiwi

  • Why KIF? Is it worth it?

  • Pros1. All objective-C.2. Its flexible. Can easily hook into your code base for real-user actions.3. Easily runs on the command line for CI.4. No external dependencies.5. Easy to integrate into your Xcode workflow.6. Use with other testing frameworks (Specta, Kiwi,etc,).7. It's open source. Large number of active contributors.

  • Cons1. Its slower than original XCTest.2. Test result format.3. It can be inconsistent at times(?!)

  • How?

  • How?

  • How?The KIF Tester uses private APIs to gain knowledge of the view hierarchy. Using the Accessibility Label value of the views.

  • How?

  • Demo, Q&A