From e085a03c0ba0cdbf54a78736a61697bca3568eab Mon Sep 17 00:00:00 2001 From: Gary Russell Date: Tue, 28 Jul 2015 16:59:23 -0400 Subject: [PATCH] INT-3401: Fix StoredProc Tests (Guava Optional) JIRA: https://jira.spring.io/browse/INT-3401 --- .../integration/jdbc/StoredProcExecutorTests.java | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/spring-integration-jdbc/src/test/java/org/springframework/integration/jdbc/StoredProcExecutorTests.java b/spring-integration-jdbc/src/test/java/org/springframework/integration/jdbc/StoredProcExecutorTests.java index c45e2080f9..c77580da4b 100644 --- a/spring-integration-jdbc/src/test/java/org/springframework/integration/jdbc/StoredProcExecutorTests.java +++ b/spring-integration-jdbc/src/test/java/org/springframework/integration/jdbc/StoredProcExecutorTests.java @@ -378,7 +378,7 @@ public class StoredProcExecutorTests { .build()); } - final CacheStats stats = storedProcExecutor.getJdbcCallOperationsCacheStatistics(); + final CacheStats stats = (CacheStats) storedProcExecutor.getJdbcCallOperationsCacheStatistics(); LOGGER.info(stats); LOGGER.info(stats.totalLoadTime() / 1000 / 1000); @@ -415,14 +415,15 @@ public class StoredProcExecutorTests { .build()); } - final CacheStats stats = storedProcExecutor.getJdbcCallOperationsCacheStatistics(); + final CacheStats stats = (CacheStats) storedProcExecutor.getJdbcCallOperationsCacheStatistics(); LOGGER.info(stats); assertEquals("Expected a cache misscount of 10", 10, stats.missCount()); } private void mockTheOperationsCache(final StoredProcExecutor storedProcExecutor) { - Object cache = TestUtils.getPropertyValue(storedProcExecutor, "jdbcCallOperationsCache.localCache"); + Object cache = TestUtils.getPropertyValue(storedProcExecutor, + "guavaCacheWrapper.jdbcCallOperationsCache.localCache"); new DirectFieldAccessor(cache) .setPropertyValue("defaultLoader", new CacheLoader() { @Override