Module: Fivemat
- Defined in:
- lib/fivemat.rb,
lib/fivemat/spec.rb,
lib/fivemat/rspec.rb,
lib/fivemat/rspec3.rb,
lib/fivemat/cucumber.rb,
lib/fivemat/cucumber3.rb,
lib/fivemat/minitest/unit.rb
Defined Under Namespace
Modules: MiniTest
Classes: Cucumber, Cucumber3, RSpec, RSpec3, Spec
Class Method Summary
collapse
Instance Method Summary
collapse
Class Method Details
.cucumber3? ⇒ Boolean
11
12
13
|
# File 'lib/fivemat.rb', line 11
def cucumber3?
defined?(::Cucumber) && ::Cucumber::VERSION >= '3'
end
|
.new(*args) ⇒ Object
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
|
# File 'lib/fivemat.rb', line 44
def self.new(*args)
case args.size
when 0 then MiniTest::Unit
when 1 then
if args.first.class.to_s == "Cucumber::Configuration"
Cucumber3
elsif rspec3?
RSpec3
else
RSpec
end
when 2 then Spec
when 3
Cucumber
else
raise ArgumentError
end.new(*args)
end
|
.rspec3? ⇒ Boolean
25
26
27
|
# File 'lib/fivemat.rb', line 25
def rspec3?
defined?(::RSpec::Core) && ::RSpec::Core::Version::STRING >= '3.0.0'
end
|
Instance Method Details
#initialize(runtime, path_or_io, options) ⇒ Object
18
19
|
# File 'lib/fivemat.rb', line 18
def initialize(config)
end
|