diff --git a/library/date/minus_month_spec.rb b/library/date/minus_month_spec.rb index 78b7d654fb..130a1bb32a 100644 --- a/library/date/minus_month_spec.rb +++ b/library/date/minus_month_spec.rb @@ -14,10 +14,10 @@ end it "raises an error on non numeric parameters" do - lambda { Date.civil(2007,2,27) << :hello }.should raise_error(NoMethodError) - lambda { Date.civil(2007,2,27) << "hello" }.should raise_error(NoMethodError) - lambda { Date.civil(2007,2,27) << Date.new }.should raise_error(NoMethodError) - lambda { Date.civil(2007,2,27) << Object.new }.should raise_error(NoMethodError) + lambda { Date.civil(2007,2,27) << :hello }.should raise_error #(TypeError) + lambda { Date.civil(2007,2,27) << "hello" }.should raise_error #(TypeError) + lambda { Date.civil(2007,2,27) << Date.new }.should raise_error #(TypeError) + lambda { Date.civil(2007,2,27) << Object.new }.should raise_error #(TypeError) end end