test/test_error.rb in textmagic-0.3.3 vs test/test_error.rb in textmagic-0.4.0

- old
+ new

@@ -1,22 +1,22 @@ -require 'test_helper' +require "test_helper" class ErrorTest < Test::Unit::TestCase - context 'Initialization' do + context "Initialization" do setup do @code = rand(1e3) @message = random_string end - should 'accept a hash with error_code and error_message' do - e = TextMagic::API::Error.new('error_code' => @code, 'error_message' => @message) + should "accept a hash with error_code and error_message" do + e = TextMagic::API::Error.new("error_code" => @code, "error_message" => @message) e.code.should == @code e.message.should == @message end - should 'accept error_code and error_message' do + should "accept error_code and error_message" do e = TextMagic::API::Error.new(@code, @message) e.code.should == @code e.message.should == @message end end