spec/namba/namba_spec.rb in namba-1.2.0 vs spec/namba/namba_spec.rb in namba-1.3.0

- old
+ new

@@ -12,18 +12,18 @@ it "should set configuration information" do Namba.configure do |config| config.username = "name" config.password = "secret" - config.locale = :kz + config.locale = :net end n = Namba.new() n.username.should == "name" n.password.should == "secret" - n.locale.should == :kz + n.locale.should == :net end it "should set defaults when it is not set in configuration block" do Namba.configure do |config| end @@ -38,22 +38,22 @@ it "should not allow to set any locale except :kg or :kz" do expect { Namba.configure do |config| config.locale = :ru end - }.should raise_error(Namba::ConfigurationError, "Available locales are only 'kg' and 'kz'") + }.to raise_error(Namba::ConfigurationError, "Available locales are only 'kg' and 'net'") end it "should raise Invalid Response Error when status code is not 200" do Namba.configure do |config| config.username = "name" config.password = "secret" - config.locale = :kz + config.locale = :net end n = Namba.new() expect { n.send(:get_response_from, "http://api.namba.#{n.locale}/404") - }.should raise_error(Namba::InvalidResponseError, "Invalid response from service") + }.to raise_error(Namba::InvalidResponseError, "Invalid response from service") end end