spec/helpers.rb in bigbench-0.0.3 vs spec/helpers.rb in bigbench-0.0.4

- old
+ new

@@ -3,14 +3,28 @@ require 'active_support/all' require 'net/http' require 'eventmachine' require 'em-http' -module Helpers +module Helpers + + def validate_normal_distribution distribution + center_index, y = (distribution.x.size / 2), distribution.y + highest_value = y[center_index] + 1 + + current_value = 0.0 + y.each do |value| + value.should <= highest_value + end + + true + end + end RSpec.configure do |config| config.include Helpers + config.treat_symbols_as_metadata_keys_with_true_values = true config.before(:each) { BigBench::Configuration.reset! BigBench::Benchmark.reset! BigBench::PostProcessor.reset! } \ No newline at end of file