spec/dineromail/notification_spec.rb in dineromail-0.1.1 vs spec/dineromail/notification_spec.rb in dineromail-0.1.2
- old
+ new
@@ -9,12 +9,10 @@
notifications.last.transaction_id.should == 5547
end
it 'should get automaticaly the status data associated with the notification' do
HTTParty.stub!(:get).and_return {
- response = Object.new
- response.stub!(:body).and_return(File.read( 'spec/fixtures/status_report.xml'))
- response
+ stub :body => File.read( 'spec/fixtures/status_report.xml')
}
notification_xml = File.read( 'spec/fixtures/notification.xml')
notifications = Dineromail::Notification.parse(notification_xml)
notification = notifications.first
notification.valid_report?.should be_true