Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP
Rspec-2 expectations (should and matchers)
Ruby

This branch is 1628 commits behind rspec:master

Fetching latest commit…

Cannot retrieve the latest commit at this time

Failed to load latest commit information.
features
lib
spec
.gitignore
.travis.yml
.yardopts
Changelog.md
Gemfile
Guardfile
License.txt
README.md
Rakefile
cucumber.yml
rspec-expectations.gemspec
specs.watchr

README.md

RSpec Expectations

rspec-expectations adds should and should_not to every object and includes RSpec::Matchers, a library of standard matchers.

build status

Documentation

The Cucumber features are the most comprehensive and up-to-date docs for end-users.

The RDoc provides additional information for contributors and/or extenders.

All of the documentation is open source and a work in progress. If you find it lacking or confusing, you can help improve it by submitting requests and patches to the rspec-expectations issue tracker.

Install

gem install rspec               # for rspec-core, rspec-expectations, rspec-mocks
gem install rspec-expectations  # for rspec-expectations only

Matchers

Matchers are objects used to compose expectations:

result.should eq("this value")

In that example, eq("this value") returns a Matcher object that compares the actual result to the expected "this value".

Contribute

See http://github.com/rspec/rspec-dev

Also see

Something went wrong with that request. Please try again.