Module: Mutineer::TestRunners::RSpecSeed::Watch
- Defined in:
- lib/mutineer/test_runners/rspec_seed.rb
Overview
Prepended on RSpec::Core::Configuration. Records a seed the suite
sets, from the command, SPEC_OPTS, .rspec, or the spec helper.
Instance Method Summary collapse
-
#force(hash) ⇒ void
CLI,
SPEC_OPTSand.rspecarrive here. -
#mark_seed_explicit ⇒ void
private
Records that this configuration object set its own seed.
-
#order=(value) ⇒ void
A spec helper's
config.order = "rand:N". -
#seed=(value) ⇒ void
A spec helper's
config.seed =.
Instance Method Details
#force(hash) ⇒ void
This method returns an undefined value.
CLI, SPEC_OPTS and .rspec arrive here. --seed is passed as
an order of rand:N.
106 107 108 109 |
# File 'lib/mutineer/test_runners/rspec_seed.rb', line 106 def force(hash) mark_seed_explicit if hash.key?(:seed) || RSpecSeed.(hash[:order]) super end |
#mark_seed_explicit ⇒ void
This method is part of a private API. You should avoid using this method if possible, as it may be removed or be changed in the future.
This method returns an undefined value.
Records that this configuration object set its own seed.
133 134 135 |
# File 'lib/mutineer/test_runners/rspec_seed.rb', line 133 def mark_seed_explicit @mutineer_seed_explicit = true end |
#order=(value) ⇒ void
This method returns an undefined value.
A spec helper's config.order = "rand:N".
124 125 126 127 |
# File 'lib/mutineer/test_runners/rspec_seed.rb', line 124 def order=(value) mark_seed_explicit if RSpecSeed.(value) super end |