aboutsummaryrefslogtreecommitdiffstats
path: root/actionpack/test/lib
diff options
context:
space:
mode:
authorDavid Heinemeier Hansson <david@loudthinking.com>2017-05-18 18:12:32 +0200
committerGitHub <noreply@github.com>2017-05-18 18:12:32 +0200
commit75fa8dd309a84e125b59d01bf182d88419631eaa (patch)
treed76aa54a79b7bf07d6e6c5d3f6c07237e5f4af60 /actionpack/test/lib
parent385d9af299fbfac7f063de214d371545bafef5df (diff)
downloadrails-75fa8dd309a84e125b59d01bf182d88419631eaa.tar.gz
rails-75fa8dd309a84e125b59d01bf182d88419631eaa.tar.bz2
rails-75fa8dd309a84e125b59d01bf182d88419631eaa.zip
Use recyclable cache keys (#29092)
Diffstat (limited to 'actionpack/test/lib')
-rw-r--r--actionpack/test/lib/controller/fake_models.rb4
1 files changed, 4 insertions, 0 deletions
diff --git a/actionpack/test/lib/controller/fake_models.rb b/actionpack/test/lib/controller/fake_models.rb
index b768553e7a..ff37d85ed8 100644
--- a/actionpack/test/lib/controller/fake_models.rb
+++ b/actionpack/test/lib/controller/fake_models.rb
@@ -26,6 +26,10 @@ Customer = Struct.new(:name, :id) do
def persisted?
id.present?
end
+
+ def cache_key
+ "#{name}/#{id}"
+ end
end
Post = Struct.new(:title, :author_name, :body, :secret, :persisted, :written_on, :cost) do