Skip to content

Commit

Permalink
added dirty check for has_one
Browse files Browse the repository at this point in the history
  • Loading branch information
Brewster committed Jun 14, 2011
1 parent 20f0faa commit b1d322c
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion spec/functional/mongoid/nested_attributes_spec.rb
Expand Up @@ -3389,7 +3389,9 @@
before do
pizza.update_attributes(params)
end

it "sets nested object to be dirty" do
pizza.crust.should be_type_changed
end
it "sets nested attributes" do
pizza.reload.crust.type.should == "Thick"
end
Expand Down

0 comments on commit b1d322c

Please sign in to comment.