Class: Scientist::Default

Inherits:
Object
  • Object
show all
Includes:
Experiment
Defined in:
lib/scientist/default.rb

Overview

A null experiment.

Instance Attribute Summary collapse

Attributes included from Experiment

#raise_on_mismatches

Instance Method Summary collapse

Methods included from Experiment

#before_run, #behaviors, #clean, #clean_value, #compare, #context, #ignore, #ignore_mismatched_observation?, included, new, #observations_are_equivalent?, #raise_on_mismatches?, #raised, #run, #run_if, #run_if_block_allows?, #should_experiment_run?, #try, #use

Constructor Details

#initialize(name) ⇒ Default

Returns a new instance of Default.



9
10
11
# File 'lib/scientist/default.rb', line 9

def initialize(name)
  @name = name
end

Instance Attribute Details

#nameObject (readonly)

Returns the value of attribute name.



7
8
9
# File 'lib/scientist/default.rb', line 7

def name
  @name
end

Instance Method Details

#enabled?Boolean

Run everything every time.

Returns:

  • (Boolean)


14
15
16
# File 'lib/scientist/default.rb', line 14

def enabled?
  true
end

#publish(result) ⇒ Object

Don’t publish anything.



19
20
# File 'lib/scientist/default.rb', line 19

def publish(result)
end