Fixed message in assertion and overrode the assertInitialized method of LazyWiringDeclarableSupport in the inner, static UserDataStoreCacheLoader test class to properly assert that the Spring defined DataSource dependency was properly configured.
This commit is contained in:
@@ -154,7 +154,7 @@ public class SpringContextBootstrappingInitializerIntegrationTest {
|
||||
.create();
|
||||
|
||||
assertNotNull("The GemFire Cache was not properly created or initialized!", gemfireCache);
|
||||
assertFalse("The GemFire Cache is close!", gemfireCache.isClosed());
|
||||
assertFalse("The GemFire Cache is closed!", gemfireCache.isClosed());
|
||||
|
||||
Set<Region<?, ?>> rootRegions = gemfireCache.rootRegions();
|
||||
|
||||
@@ -258,6 +258,14 @@ public class SpringContextBootstrappingInitializerIntegrationTest {
|
||||
getClass().getName()));
|
||||
}
|
||||
|
||||
@Override
|
||||
protected void assertInitialized() {
|
||||
super.assertInitialized();
|
||||
Assert.state(userDataSource != null, String.format(
|
||||
"The 'User' Data Source was not properly configured and initialized for use in (%1$s!)",
|
||||
getClass().getName()));
|
||||
}
|
||||
|
||||
protected DataSource getDataSource() {
|
||||
return userDataSource;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user