Class Index [+]

Quicksearch

Kernel

Public Instance Methods

debugger(steps=1) click to toggle source

Start a debugging session if ruby-debug is loaded with the -u/--debugger option

   # File lib/spec/runner/extensions/kernel.rb, line 4
4:     def debugger(steps=1)
5:       # If not then just comment and proceed
6:       $stderr.puts "debugger statement ignored, use -u or --debugger option on rspec to enable debugging"
7:     end
should(matcher) should == expected should === expected should =~ expected click to toggle source
  receiver.should(matcher)
    => Passes if matcher.matches?(receiver)

  receiver.should == expected #any value
    => Passes if (receiver == expected)

  receiver.should === expected #any value
    => Passes if (receiver === expected)

  receiver.should =~ regexp
    => Passes if (receiver =~ regexp)

See Spec::Matchers for more information about matchers

Warning

NOTE that this does NOT support receiver.should != expected. Instead, use receiver.should_not == expected

    # File lib/spec/expectations/extensions/kernel.rb, line 26
26:   def should(matcher=nil, message=nil, &block)
27:     Spec::Expectations::PositiveExpectationHandler.handle_matcher(self, matcher, message, &block)
28:   end
should_not(matcher) should_not == expected should_not === expected should_not =~ expected click to toggle source
  receiver.should_not(matcher)
    => Passes unless matcher.matches?(receiver)

  receiver.should_not == expected
    => Passes unless (receiver == expected)

  receiver.should_not === expected
    => Passes unless (receiver === expected)

  receiver.should_not =~ regexp
    => Passes unless (receiver =~ regexp)

See Spec::Matchers for more information about matchers

    # File lib/spec/expectations/extensions/kernel.rb, line 49
49:   def should_not(matcher=nil, message=nil, &block)
50:     Spec::Expectations::NegativeExpectationHandler.handle_matcher(self, matcher, message, &block)
51:   end

Disabled; run with --debug to generate this.

[Validate]

Generated with the Darkfish Rdoc Generator 1.1.6.