From 861e4817559dfb956512775665c8f0c9da9c99c1 Mon Sep 17 00:00:00 2001 From: Costin Leau Date: Tue, 17 May 2011 17:09:49 +0000 Subject: [PATCH] revise cache API + update failing test --- .../springframework/cache/config/AbstractAnnotationTest.java | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/org.springframework.context/src/test/java/org/springframework/cache/config/AbstractAnnotationTest.java b/org.springframework.context/src/test/java/org/springframework/cache/config/AbstractAnnotationTest.java index d6873e0729..95ce7dab09 100644 --- a/org.springframework.context/src/test/java/org/springframework/cache/config/AbstractAnnotationTest.java +++ b/org.springframework.context/src/test/java/org/springframework/cache/config/AbstractAnnotationTest.java @@ -135,7 +135,7 @@ public abstract class AbstractAnnotationTest { assertSame(r1, service.name(key)); Cache cache = cm.getCache("default"); // assert the method name is used - assertTrue(cache.containsKey(keyName)); + assertNotNull(cache.get(keyName)); } public void testRootVars(CacheableService service) { @@ -145,7 +145,7 @@ public abstract class AbstractAnnotationTest { Cache cache = cm.getCache("default"); // assert the method name is used String expectedKey = "rootVarsrootVars" + AopProxyUtils.ultimateTargetClass(service) + service; - assertTrue(cache.containsKey(expectedKey)); + assertNotNull(cache.get(expectedKey)); } public void testNullArg(CacheableService service) {