hi,

I am kind of confused, why this code is behaving the way it does.
In a test, I wrote something like this:

it "should do something" do
  @some = Factory(:some)
  initial_object = @some

  #do something with @some. e.g. update attributes etc.
  @some.reload
  @some.should_not == initial_object
end


Whenever I call reload on the object, the initial_object is set to
object again.
I don't understand why a reload on @some is also updating
initial_object.
Can someone explain this to me please?
_______________________________________________
rspec-users mailing list
rspec-users@rubyforge.org
http://rubyforge.org/mailman/listinfo/rspec-users

Reply via email to