spec/wbench/timing_hash_spec.rb in wbench-1.1.0 vs spec/wbench/timing_hash_spec.rb in wbench-1.1.1
- old
+ new
@@ -2,19 +2,19 @@
describe '#new' do
let(:timings) { { :end => 20, :middle => 15, :start => 10, :nope => 0 } }
subject { described_class.new(timings) }
it 'removes keys with a value of 0' do
- subject.should_not have_key :nope
+ expect(subject).not_to have_key :nope
end
it 'offsets each value by the starting(lowest) value' do
- subject[:start].should == 0
- subject[:middle].should == 5
- subject[:end].should == 10
+ expect(subject[:start]).to eq(0)
+ expect(subject[:middle]).to eq(5)
+ expect(subject[:end]).to eq(10)
end
it 'orders the hash by value, lowest first' do
- subject.first.should == [:start, 0]
+ expect(subject.first).to eq([:start, 0])
end
end
end