diff --git a/lib/machinist/sequel.rb b/lib/machinist/sequel.rb index 48215f3..b81530c 100644 --- a/lib/machinist/sequel.rb +++ b/lib/machinist/sequel.rb @@ -37,7 +37,6 @@ def make(*args, &block) lathe = Lathe.run(Machinist::SequelAdapter, self.new, *args) unless Machinist.nerfed? lathe.object.save - lathe.object.refresh end lathe.object(&block) end diff --git a/spec/sequel_spec.rb b/spec/sequel_spec.rb index 98cdc72..3591f41 100644 --- a/spec/sequel_spec.rb +++ b/spec/sequel_spec.rb @@ -57,6 +57,12 @@ class Comment < Sequel::Model person = Person.make person.should_not be_new end + + it "should reload object after save with column default values" do + Person.blueprint { } + person = Person.make + person.admin.should == false + end it "should create and object through a many_to_one association" do Post.blueprint { }