Class: Mutiny::Integration::RSpec

Inherits:
Mutiny::Integration show all
Defined in:
lib/mutiny/integration/rspec.rb,
lib/mutiny/integration/rspec/hook.rb,
lib/mutiny/integration/rspec/test.rb,
lib/mutiny/integration/rspec/parser.rb,
lib/mutiny/integration/rspec/runner.rb,
lib/mutiny/integration/rspec/context.rb,
lib/mutiny/integration/rspec/test_set.rb

Overview

This code originally based on Markus Schirp’s implementation of Mutant::Integration::Rspec

https://github.com/mbj/mutant/blob/master/lib/mutant/integration/rspec.rb

Defined Under Namespace

Classes: Context, Hook, Parser, Runner, Test, TestSet

Instance Method Summary collapse

Instance Method Details

#run(test_set, hooks: [], **options) ⇒ Object



15
16
17
18
# File 'lib/mutiny/integration/rspec.rb', line 15

def run(test_set, hooks: [], **options)
  rspec_hooks = hooks.map { |hook| RSpec::Hook.new(hook) }
  Runner.new(test_set, context(options), rspec_hooks).call
end

#tests(options = {}) ⇒ Object



11
12
13
# File 'lib/mutiny/integration/rspec.rb', line 11

def tests(options = {})
  Parser.new(context(options)).call
end