John Blum
db03332430
Add Bash shell script source file to cleanup (delete) all Apach Geode files created at runtime.
2021-03-30 16:44:31 -07:00
John Blum
2e26da27c4
Remove the deprecated SubscriptionEnabledClientServerIntegrationTestsConfiguration class.
2021-03-29 15:30:06 -07:00
John Blum
bef3a7a874
Include test logic and configuration to terminate a (forked) Spring application so it does not run indefinitely.
2021-03-29 15:25:02 -07:00
John Blum
bb06ce59a9
Remove unnecessary @SuppressWarnings('All') annotation declarations.
...
Format source code.
2021-03-29 15:24:18 -07:00
John Blum
2729e537f6
Add @AfterClass test logic to cleanup non-Standard Spring container Environment PropertySources if available.
2021-03-29 14:16:04 -07:00
John Blum
08aefff97d
Rename the mockThePoolFactoryBean(:PoolFactoryBean) method to mockPoolFactoryBean(:PoolFactoryBean).
...
Add/edit Javadoc.
Consistently apply Spring's @NonNull and @Nullable annotations to the API.
2021-03-29 11:37:36 -07:00
John Blum
52cc90c698
Refactor use of Spring's @NonNull & @Nullable annotations in the API.
2021-03-29 11:25:51 -07:00
John Blum
c803efa301
Fix Javadoc tags and code blocks.
2021-03-22 20:27:23 -07:00
John Blum
40baf02fdd
Add Integration Tests testing and asserting the publishing of Apache Geode cache lifecycle events through the Spring container (using the ApplicationEventPublisher with custom cache ApplicationEvents).
2021-03-22 20:16:28 -07:00
John Blum
bc9625ebcf
Cleanup compiler warnings.
2021-03-22 20:14:48 -07:00
John Blum
26d6a6e511
Add Integration Tests testing and asserting the behavior of the Spring TestContext framework with regard to managing ApplicationContexts created, managed and used by test cases of test classes.
2021-03-22 20:10:37 -07:00
John Blum
b1fdb5962e
Add TestContextApplicationEventPublisherAdapter class adapting the Spring TestContext framework and API as an instance of the ApplicationEventPublisher interface.
2021-03-22 20:08:41 -07:00
John Blum
9e03dc03c6
Add GeodeContextCustomizer and factory used to customize the Spring ApplicationContext setup during Integration Tests involving Apache Geode.
2021-03-22 20:07:46 -07:00
John Blum
3b5208c213
Add (experimental) DependencyOf annotation type and associated DependencyOfBeanFactoryPostProcessor class.
...
The @DependencyOf annotation is the inverse of Spring's @DependsOn annotation enabling a bean to declare itself as a dependency for another bean in the Spring ApplicationContext (container).
2021-03-22 20:05:34 -07:00
John Blum
08350ab997
Rename the AbstractApplicationContextCacheLifecycleListenerAdapter class to AbstractApplicationEventPublisherCacheLifecycleListenerAdapter.
...
Refactor the TestContextCacheLifecycleListenerAdapter class making it a proper Singleton (i.e. a final class with private constructor).
Add isOpen(:GemFireCache) method to TestContextCacheLifecycleListenerAdapter.
Rename cacheReferences to cacheInstances.
2021-03-22 19:48:53 -07:00
John Blum
59488b0a54
Move TestContextEventType enumeration to the org.springframework.data.gemfire.tests.extensions.spring.test.context.event package.
2021-03-22 19:42:38 -07:00
John Blum
dfd0d8e324
Move the GemFireUnitTest annotation to the org.springframework.data.gemfire.tests.unit.annotation package.
2021-03-22 19:37:36 -07:00
John Blum
103cb930ba
Refactor codebase.
...
Apply Spring @NonNull & @Nullable annotations to the API.
2021-03-22 19:37:36 -07:00
John Blum
54e8b1ecde
Refactor codebase.
...
Apply Spring @NonNull and @Nullable annotations to the API.
2021-03-22 19:37:36 -07:00
John Blum
14fa273445
Improve test context/infrastructure logic to reliably determine whether the GemFire/Geode cache instance was properly closed.
...
This test logic is necessary to prevent interference between tests, particularly for integration tests involving live GemFire/Geode objects, especially since GemFire/Geode is rife with Singletons.
For example, SSL configuration settings linger between tests if the cache is not fully closed (when all resources are adequately released) in a timely manner.
2021-03-22 19:36:56 -07:00
John Blum
3d13306ace
Rename IntegrationTestsSupport.clearAllBeanFactoryLocators() method to closeAllBeanFactoryLocators().
2021-03-18 12:34:13 -07:00
John Blum
80bd2d19ab
Add RegionSpyingBeanPostProcessor class to spy on Region beans managed in a Spring TestContext for testing purposes.
2020-12-11 13:46:45 -08:00
John Blum
77ac40d653
Add @Configuration class for Locator only.
...
Add @Configuration class for Manager only.
2020-11-03 10:41:10 -08:00
John Blum
b40dd309bc
Extend IntegrationTestsSupport.
2020-09-16 19:52:20 -07:00
John Blum
e25cdb363c
Provide mock stubbing support for GemfireRepository.count() method when GemFire Mock Objects is enabled.
2020-09-16 19:25:06 -07:00
John Blum
e0eaeacc60
Annotate mockRegionDataAccessOperations(..) with @SuppressWarnings('unchecked').
...
Annotate mockSelectResults() and mockLucenceIndexFactory(..) with @SuppressWarnings('unchecked').
2020-09-16 16:19:30 -07:00
John Blum
f144f98271
Mock the Map/Region.values() operation.
2020-09-16 15:25:37 -07:00
John Blum
efed3af760
Use doAnswer(..) instead of thenAnswer(..) Mockito mock stubbing for mock Region.remove(key).
2020-09-16 14:59:31 -07:00
John Blum
8c32143918
Mock the Region.removeAll(:Collection<K>) operation.
2020-09-16 14:50:12 -07:00
John Blum
e453578340
Mock the Map/Region.putAll(:Map<K, V>) operation.
2020-09-16 14:33:07 -07:00
John Blum
22e950c19a
Use doAnswer(..) instead of thenAnser(..) Mockito mock stubbing for mock Region.put(key, value).
2020-09-16 13:48:03 -07:00
John Blum
e718b595f6
Mock the Region.localInvalidate(key) operation; call mock Region.invalidate(key).
2020-09-16 13:35:57 -07:00
John Blum
ab686fe92c
Mock the Region.localClear() operation; call mock Region.clear().
2020-09-16 13:32:07 -07:00
John Blum
1a10296740
Mock the Map/Region.keySet() operation.
2020-09-16 13:23:37 -07:00
John Blum
f5fe40dfcd
Mock the Map/Region.isEmpty() operation.
2020-09-16 13:14:24 -07:00
John Blum
051447a76d
Mock the Region.getParentRegion() operation for sub-Regions.
2020-09-16 12:51:02 -07:00
John Blum
74634337fb
Mock the Map.getOrDefault(key, defaultValue) operation.
2020-09-16 12:20:28 -07:00
John Blum
2e94141994
Use doAnser(..) instead of thenAnser(..) Mockito mock stubbing for getSubregions(..) and subregions(..) operations on mock Region.
2020-09-16 12:13:05 -07:00
John Blum
f896abd33b
Refactor all mock Region data access operations into a separate method.
2020-09-16 12:08:59 -07:00
John Blum
16c7ddeeb9
Mock the Region.getAll(:Collection<K>) operation.
2020-09-16 12:02:46 -07:00
John Blum
028f9c16da
Use doAnswer(..) instead of thenAnser(..) Mockito mock stubbing for Map/Region.get(key).
2020-09-15 19:42:58 -07:00
John Blum
ea2241847a
Mock the Map.forEach(:BiConsumer<K, V>) operation.
2020-09-15 19:35:55 -07:00
John Blum
06cdda618d
Mock the Region.containsValueForKey(key) operation.
2020-09-15 19:11:41 -07:00
John Blum
e7c106f4ca
Mock the Map/Region.containsValue(value) operation.
2020-09-15 18:58:05 -07:00
John Blum
ed94c009bb
Write test for the Map/Region.containsKey(key) operation.
2020-09-15 18:58:05 -07:00
John Blum
301deb1330
Mock the Map/Region.clear() operation.
2020-09-15 18:50:46 -07:00
John Blum
528818b9fd
Mock SelectResults.iterator().
...
Change access modifier on GemFireMockObjectsSupport.mockSelectResults() to private.
2020-08-28 15:07:36 -07:00
John Blum
f2779cd8d7
Mock ClientCache.getQueryService(poolName:String).
...
Mock QueryService.newQuery(:String).
Mock Query.execute(..).
Mock SelectResults<?>, ObjectType and CollectionType.
2020-08-28 14:50:10 -07:00
John Blum
cb28c5f4df
If trying to delete a file fails then schedule the file to be deleted on exit.
2020-08-28 10:41:13 -07:00
John Blum
d9b3ac9ce3
Recurse on collectGemFireResources(:File) when deleting a target GemFire/Geode directory.
...
Replaces FileSystemUtils.deleteRecursive(:File).
Edit Javadoc.
2020-08-27 16:29:09 -07:00