Class: RSpec::Core::Hooks::BeforeHooks

Inherits:
HookCollection show all
Defined in:
lib/rspec/core/hooks.rb

Instance Method Summary collapse

Methods inherited from HookCollection

#find_hooks_for, #without_hooks_for

Instance Method Details

#run_all(example_group_instance) ⇒ Object



63
64
65
# File 'lib/rspec/core/hooks.rb', line 63

def run_all(example_group_instance)
  each {|h| h.run_in(example_group_instance) } unless empty?
end

#run_all!(example_group_instance) ⇒ Object



67
68
69
# File 'lib/rspec/core/hooks.rb', line 67

def run_all!(example_group_instance)
  shift.run_in(example_group_instance) until empty?
end