Hi all, I hope someone can help me with this.
I'm trying to write a test to see if my versioning (acts_as_versioned) works. In order to do that, I have a class which inherits from ActiveRecord: class Order < ActiveRecord::Base
However, when I try to update or to create a new order within the test, my changes do not affect the DB: o = Order.create(:name => 'n', :email => 'e', :address => 'a', :pay_type => 'po') o.save o.name = 'm' o.save order = Order.find(@first_id) #order.pay_type = 'po'; order.address = 'dummy address'; order.email = 'd@d.d'; order.name = 'first ammended' order.update_attributes({ :pay_type => 'po', :address => '123 hh road', :email => 'r@r.r', :name => '2nd ammended'})
I run this, and nothing is committed to the DB! Can anyone help?
Thanks