Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP
BDD-style testing using Objective-C
Objective-C++ Objective-C C++ Ruby Other
Failed to load latest commit information.
Cedar-iOS-Framework Spec Remove unused xib files
Cedar-iOS-Framework Add Framework test suite
Cedar.xcodeproj Reorganized headers
CedarPlugin.xcplugin/Contents Update cedar plugin for Xcode 6.4
CodeSnippetsAndTemplates Update templates to work with Xcode 6.3
English.lproj Initial commit
OCUnitApp Bumps version to 0.11.1
OCUnitAppLogicTests Suppressed SenTestingKit warning.
OCUnitAppTests Fail tests correctly under SenTestingKit
OS X Failing Test Bundle Usability for Cedar Test Bundle + Testing script tweaks.
OS X Host App Remove unused xib files
OS X Host AppTests Usability for Cedar Test Bundle + Testing script tweaks.
OS X XCTest Bundle Usability for Cedar Test Bundle + Testing script tweaks.
Source Merge pull request #350 from briancroom/fixup-header-visibility
Spec Fix crash when adding a block stub to certain methods
XCUnitAppTests Fix for running specs under SenTestingKit or XCTest.
images Add a screenshot of the Cedar file template picker for the Alcatraz e…
.gitignore RaiseException matcher extended to handle NSException' name
.travis.yml Travis to attempt running the install scripts. Remove installing subm…
Cedar-Info.plist Version 0.11.3
Cedar.podspec Update podspec to respect project & public headers
Gemfile Adds feature for failure to link AppDelegate
Gemfile.lock Upgrade gems
MIT.LICENSE.txt Renamed LICENSE file for cocoapod's linting.
README.markdown Update the Readme’s Quick Start section to mention Cocoapods, Carthag…
Rakefile Installing code snippets no longer builds frameworks
iOSSpecs-Info.plist Bumps version to 0.11.1
install.sh Travis to attempt running the install scripts. Remove installing subm…
installCodeSnippetsAndTemplates Allow any rake version during install
upgradeCedarFramework Made upgradeCedarFramework work with paths containing spaces

README.markdown

Cedar

Build Status Carthage compatible

Cedar is a BDD-style Objective-C testing framework with an expressive matcher DSL and convenient test doubles.

describe(@"Example specs on NSString", ^{
    it(@"lowercaseString returns a new string with everything in lower case", ^{
        [@"FOOBar" lowercaseString] should equal(@"foobar");
    });

    it(@"length returns the number of characters in the string", ^{
        [@"internationalization" length] should equal(20);
    });

    describe(@"isEqualToString:", ^{
        it(@"should return true if the strings are the same", ^{
            [@"someString" isEqualToString:@"someString"] should be_truthy;
        });

        it(@"should return false if the strings are not the same", ^{
            [@"someString" isEqualToString:@"anotherString"] should be_falsy;
        });
    });
});

Note for Xcode 7 users

With Xcode 7, Apple has introduced changes to XCTest.framework which are incompatible with Cedar's test bundle runner. (See #333 for more details.) Support for Xcode 7 is being actively developed on the Xcode7 branch which should be used until we feel that the Xcode 7 betas have stabilized and we are ready to merge this work into the master branch.

Quick start

    $ curl -L https://raw.github.com/pivotal/cedar/master/install.sh | bash
  • Or if you want to install from HEAD. Run:
    $ bash <(echo "set -- --head; $(curl -L https://raw.github.com/pivotal/cedar/master/install.sh)")
  • Restart Xcode
  • Add new spec files to your project's Test Bundle using the Xcode templates
  • Start writing specs!

Documentation

Documentation can be found on the Cedar Wiki.

Support and feedback

Contributing

Please read the Contributor Guide on the wiki.

Maintainers

Copyright (c) 2010-2014 Pivotal Labs. This software is licensed under the MIT License. Mixpanel

Something went wrong with that request. Please try again.