Code Monkey home page Code Monkey logo

kif-kiwi's Introduction

KIF-Kiwi

Write KIF tests Kiwi style!

KIF-Kiwi is a bridge between the Keep It Functional and Kiwi frameworks. It allows you to perform KIF actions using Kiwi syntax.

CI Status Version License Platform

Installation

KIF-Kiwi is available through CocoaPods. To install KIF-Kiwi, simply add the following line to your Podfile:

pod 'KIF-Kiwi'

and run

pod install

Usage

Include KIF-Kiwi in your specs and start writing KIF tests using Kiwi describe/context and it blocks. See the TestableSpec.m example:

#import <KIF-Kiwi.h>

SPEC_BEGIN(MainViewAppSpec)

	describe(@"Main view", ^{
		
		it(@"should have tappable button", ^{
            [tester tapViewWithAccessibilityLabel:@"Tap me"];
            [tester waitForViewWithAccessibilityLabel:@"Button tapped!"];
		});

	});
	
SPEC_END

Please see the KIF and Kiwi documentation for more information on these frameworks.

Testing

To begin running the example project tests, clone the repo, and open xcode workspace in the Example directory:

git clone https://github.com/IndieGoGo/KIF-Kiwi.git
cd KIF-Kiwi/Example/
open KIF-Kiwi.xcworkspace

Press ⌘-U in Xcode or select Product->Test from the menu to run the tests.

You can also run the example tests from the command-line:

xcodebuild test -workspace KIF-Kiwi.xcworkspace -scheme KIF-Kiwi -sdk iphonesimulator

or by using xctool:

xctool test

The test output will show a description of the test:

━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
2014-08-01 02:28:15.661 KIF-Kiwi[14407:70b] + 'Testable, should have working button' [PASSED]
━━━━┳━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
    ✓ -[SampleAppSpec Testable_ShouldHaveWorkingButton] (761 ms)
    1 passed, 0 failed, 0 errored, 1 total (761 ms)

** TEST SUCCEEDED: 1 passed, 0 failed, 0 errored, 1 total ** (13862 ms)

Contributing

Please report any issues. PRs are always welcome!

To submit a PR:

  1. Fork it
  2. Create your feature branch (git checkout -b my-new-feature)
  3. Commit your changes (git commit -am 'Add some feature')
  4. Push to the branch (git push origin my-new-feature)
  5. Create new Pull Request

Requirements

  • Xcode >= 5.1
  • iOS 7

Authors

License

KIF-Kiwi is available under the MIT license. See the LICENSE file for more info.

kif-kiwi's People

Contributors

paulz avatar gogopair avatar izhan avatar indieirvin avatar gogogadget avatar indiekevin avatar

Watchers

James Cloos avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.