public
Description: BDD that talks to domain experts first and code second
Home | Edit | New

RSpec Expectations

To use RSpec’s expectations (should), make sure the following is in features/support/env.rb:

require 'spec/expectations'

'spec/expectations' also includes 'spec/matchers'. When cucumber sees the Spec::Matchers and Spec::Expectations modules defined, it will implicitly include them in the World in which the steps are executed.

Do not require 'spec', because that loads up a bunch of RSpec modules that you don’t need and might get in your way.

Last edited by aslakhellesoy, Mon Mar 30 23:18:59 -0700 2009
Home | Edit | New
Versions: