spec/unit/ipmitool/errorcodes_spec.rb in rubyipmi-0.8.1 vs spec/unit/ipmitool/errorcodes_spec.rb in rubyipmi-0.9.0

- old
+ new

@@ -1,23 +1,24 @@ -require File.expand_path(File.dirname(__FILE__) + '/../../spec_helper') +require 'spec_helper' + require 'rubyipmi/ipmitool/errorcodes' describe "Errorcodes" do it 'should return the length of fix hash' do - Rubyipmi::Ipmitool::ErrorCodes.length.should be > 1 + expect(Rubyipmi::Ipmitool::ErrorCodes.length).to be > 1 end it 'should return a hash of codes' do - Rubyipmi::Ipmitool::ErrorCodes.code.should be_an_instance_of Hash + expect(Rubyipmi::Ipmitool::ErrorCodes.code).to be_an_instance_of Hash end it 'should return a fix if code is found' do code = 'Authentication type NONE not supported' - Rubyipmi::Ipmitool::ErrorCodes.search(code).should eq({"I"=>"lanplus"}) + expect(Rubyipmi::Ipmitool::ErrorCodes.search(code)).to eq({"I"=>"lanplus"}) end it 'should throw and error if no fix is found' do code = 'Crap Shoot' expect {Rubyipmi::Ipmitool::ErrorCodes.search(code)}.to raise_error \ No newline at end of file