From 9e63f9f2e42a3cbfd7b36e47ee5a7c94da757152 Mon Sep 17 00:00:00 2001 From: Sebi Burkhard Date: Fri, 8 Jul 2011 18:08:37 +0700 Subject: Properly cache value when it is "false" --- activesupport/test/caching_test.rb | 5 +++++ 1 file changed, 5 insertions(+) (limited to 'activesupport/test') diff --git a/activesupport/test/caching_test.rb b/activesupport/test/caching_test.rb index ed5ccb44de..498127e5bc 100644 --- a/activesupport/test/caching_test.rb +++ b/activesupport/test/caching_test.rb @@ -188,6 +188,11 @@ module CacheStoreBehavior assert_equal nil, @cache.read('foo') end + def test_should_read_and_write_false + assert_equal true, @cache.write('foo', false) + assert_equal false, @cache.read('foo') + end + def test_read_multi @cache.write('foo', 'bar') @cache.write('fu', 'baz') -- cgit v1.2.3