Permalink
Browse files

Add a regression test on #8195

  • Loading branch information...
1 parent 8f3f50a commit ff2973a09a5b76473a62cc75e77851a5715d5a33 @nikitug nikitug committed Nov 13, 2012
Showing with 7 additions and 0 deletions.
  1. +7 −0 activerecord/test/cases/base_test.rb
@@ -1442,6 +1442,13 @@ def test_cache_key_format_for_existing_record_with_nil_updated_at
assert_match(/\/#{dev.id}$/, dev.cache_key)
end
+ def test_cache_key_format_is_precise_enough
+ dev = Developer.first
+ key = dev.cache_key
+ dev.touch
+ assert_not_equal key, dev.cache_key
+ end
+
def test_uniq_delegates_to_scoped
scope = stub
Bird.stubs(:all).returns(mock(:uniq => scope))

0 comments on commit ff2973a

Please sign in to comment.