Module Kernel
In: lib/spec/expectations/extensions/kernel.rb
lib/spec/runner/extensions/kernel.rb

Methods

debugger   should   should_not  

Public Instance methods

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

  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

  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

[Validate]