aboutsummaryrefslogtreecommitdiffstats
path: root/actionpack/test/lib/controller/fake_models.rb
diff options
context:
space:
mode:
Diffstat (limited to 'actionpack/test/lib/controller/fake_models.rb')
-rw-r--r--actionpack/test/lib/controller/fake_models.rb5
1 files changed, 5 insertions, 0 deletions
diff --git a/actionpack/test/lib/controller/fake_models.rb b/actionpack/test/lib/controller/fake_models.rb
index cf3f2f7fa4..dba632e6df 100644
--- a/actionpack/test/lib/controller/fake_models.rb
+++ b/actionpack/test/lib/controller/fake_models.rb
@@ -55,6 +55,11 @@ class Post < Struct.new(:title, :author_name, :body, :secret, :written_on, :cost
alias_method :secret?, :secret
+ def initialize(*args)
+ super
+ @persisted = false
+ end
+
def persisted=(boolean)
@persisted = boolean
end