Remove assertion on the cache instance asserting whether the cache was an instance of o.a.g.internal.cache.GemFireCacheImpl.

Remove assertion on the Region instance asserting whether the Region was an instance of o.a.g.internal.cache.AbstractRegion.

Resolves gh-70.
This commit is contained in:
John Blum
2020-02-21 20:13:00 -08:00
parent 8e88abfebe
commit 51e7b0e9f9

View File

@@ -25,8 +25,6 @@ import org.junit.runner.RunWith;
import org.apache.geode.cache.Region;
import org.apache.geode.cache.client.ClientCache;
import org.apache.geode.internal.cache.AbstractRegion;
import org.apache.geode.internal.cache.GemFireCacheImpl;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.boot.SpringBootConfiguration;
@@ -37,6 +35,7 @@ import org.springframework.data.gemfire.config.annotation.EnableCachingDefinedRe
import org.springframework.data.gemfire.tests.integration.IntegrationTestsSupport;
import org.springframework.data.gemfire.tests.mock.annotation.EnableGemFireMockObjects;
import org.springframework.geode.boot.autoconfigure.CachingProviderAutoConfiguration;
import org.springframework.geode.util.GeodeAssertions;
import org.springframework.test.context.junit4.SpringRunner;
import example.test.service.TestCacheableService;
@@ -75,10 +74,11 @@ public class AutoConfiguredCachingUnitTests extends IntegrationTestsSupport {
public void setup() {
assertThat(this.clientCache).isNotNull();
assertThat(this.clientCache).isNotInstanceOf(GemFireCacheImpl.class);
assertThat(this.randomNumbers).isNotNull();
// TODO: Why is AbstractRegion internal!?!?! #argh
assertThat(this.randomNumbers).isNotInstanceOf(AbstractRegion.class);
GeodeAssertions.assertThat(this.clientCache).isNotInstanceOfGemFireCacheImpl();
GeodeAssertions.assertThat(this.randomNumbers).isNotInstanceOfAbstractRegion();
assertThat(this.cacheableService).isNotNull();
assertThat(this.cacheableService.isCacheMiss()).isFalse();
}