module Rspec::Core::ExampleGroupSubject::ClassMethods
def subject(&block)
end
it { should_not be_overdrawn }
it { should have_a_balance_of(50, :USD) }
subject { CheckingAccount.new(:amount => 50, :currency => :USD) }
describe CheckingAccount, "with $50" do
== Examples
implicit receiver (through delegation) of calls to +should+.
Defines an explicit subject for an example group which can then be the
def subject(&block) block.nil? ? explicit_subject || implicit_subject : @explicit_subject_block = block end