Sha256: 1441a5923c396ea98f1752e467d3e15b397de09b670791c759146a32c264a44d

Contents?: true

Size: 821 Bytes

Versions: 5

Compression:

Stored size: 821 Bytes

Contents

require_relative "./helpers"

describe BigBench::Bot do
  
  before(:each) do
    BigBench::Store.reset!
  end
  
  it "should check for an empty receipt" do
    BigBench::Store.setup!("http://localhost:6379").should be_true
    
    BigBench::Bot.check_test!
    BigBench.benchmarks.size.should == 0
  end
  
  it "should load and run a test from the redis store" do
    BigBench::Store.setup!("http://localhost:6379").should be_true
    
    test = File.open("spec/tests/local.rb", "rb"){ |file| file.read }
    BigBench::Store.test = test
    BigBench::Store.start
    
    BigBench::Bot.check_test!
    
    BigBench.config.mode.should == :bot
    BigBench.benchmarks.size.should == 2
    BigBench.benchmarks.each{ |benchmark| benchmark.runs.should == 1 }
    BigBench::Store.count_trackings.should > 100
  end
  
end

Version data entries

5 entries across 5 versions & 1 rubygems

Version Path
bigbench-0.0.5 spec/bot_spec.rb
bigbench-0.0.4 spec/bot_spec.rb
bigbench-0.0.3 spec/bot_spec.rb
bigbench-0.0.2 spec/bot_spec.rb
bigbench-0.0.1 spec/bot_spec.rb