Parent

Class/Module Index [+]

Quicksearch

Spec::Runner::ExampleGroupRunner

Public Class Methods

new(options) click to toggle source
# File lib/spec/runner/example_group_runner.rb, line 4
def initialize(options)
  @options = options
end

Public Instance Methods

load_files(files) click to toggle source
# File lib/spec/runner/example_group_runner.rb, line 8
def load_files(files)
  $KCODE = 'u' if RUBY_VERSION.to_f < 1.9
  # It's important that loading files (or choosing not to) stays the
  # responsibility of the ExampleGroupRunner. Some implementations (like)
  # the one using DRb may choose *not* to load files, but instead tell
  # someone else to do it over the wire.
  files.each do |file|
    load file
  end
end
run() click to toggle source
# File lib/spec/runner/example_group_runner.rb, line 19
def run
  prepare
  success = true
  example_groups.each do |example_group|
    success = success & example_group.run(@options)
  end
  finish
  success
end

Protected Instance Methods

example_groups() click to toggle source
# File lib/spec/runner/example_group_runner.rb, line 49
def example_groups
  @options.example_groups
end
finish() click to toggle source
# File lib/spec/runner/example_group_runner.rb, line 36
def finish
  reporter.end
  reporter.dump
end
number_of_examples() click to toggle source
# File lib/spec/runner/example_group_runner.rb, line 53
def number_of_examples
  @options.number_of_examples
end
prepare() click to toggle source
# File lib/spec/runner/example_group_runner.rb, line 31
def prepare
  reporter.start(number_of_examples)
  example_groups.reverse! if reverse
end
reporter() click to toggle source
# File lib/spec/runner/example_group_runner.rb, line 41
def reporter
  @options.reporter
end
reverse() click to toggle source
# File lib/spec/runner/example_group_runner.rb, line 45
def reverse
  @options.reverse
end

[Validate]

Generated with the Darkfish Rdoc Generator 2.