Re: [rspec-users] object_instance.reload and print out a message placed in the model

2011-02-22 Thread Justin Ko
On Tue, Feb 22, 2011 at 10:08 AM, Daniel Salmerón Amselem < daniel.amse...@gmail.com> wrote: > Thanks, I'll try that. I just have the feeling ActiveRecord caches are > being a pain in the ass. For example, the toggle_resource method removes or > adds a resource to a group, and when just after that

Re: [rspec-users] object_instance.reload and print out a message placed in the model

2011-02-22 Thread Daniel Salmerón Amselem
Thanks, I'll try that. I just have the feeling ActiveRecord caches are being a pain in the ass. For example, the toggle_resource method removes or adds a resource to a group, and when just after that I check the resources on that group, I still get the same ones before the toggle_resource method wa

Re: [rspec-users] object_instance.reload and print out a message placed in the model

2011-02-21 Thread Justin Ko
On Mon, Feb 21, 2011 at 5:18 AM, Daniel Salmeron Amselem < daniel.amse...@gmail.com> wrote: > I'm trying to test this with Ruby 1.9.2, RSpec 2.5.0, and Rails 3.0.4: > > context "toggle_resource method" do > it "should remove the resource from the group" do > group = Factory(:unique_gro

[rspec-users] object_instance.reload and print out a message placed in the model

2011-02-21 Thread Daniel Salmeron Amselem
I'm trying to test this with Ruby 1.9.2, RSpec 2.5.0, and Rails 3.0.4: context "toggle_resource method" do it "should remove the resource from the group" do group = Factory(:unique_group) user = Factory(:unique_user, :account => group.account) group.add_resource(user)