John Blum
fcf1842e02
Add Spring BeanPostProcessor to initialize an Apache Geode Region (bean) with data on Spring container initialization.
2021-09-24 16:45:07 -07:00
John Blum
61316b8631
Change all JUnit declared @BeforeClass Spring and Apache Geode object and resource cleanup to occur after test (class/suite) execution using JUnit's @AfterClass.
...
Edit Javadoc.
2021-09-16 22:56:50 -07:00
John Blum
87a7bc8e49
Fix bug with DistributedSystem Properties handling in mock object configuration.
2021-09-13 14:39:48 -07:00
John Blum
20e401e94f
Fix bugs in mock Index logic regarding (mock) Region references.
2021-09-10 17:26:14 -07:00
John Blum
70cf67cf45
Fix bugs in mock Lucene objects functionality.
2021-09-10 16:51:28 -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
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
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
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
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
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
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
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
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
16c7ddeeb9
Mock the Region.getAll(:Collection<K>) operation.
2020-09-16 12:02:46 -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
d2bd431e43
Replace all references to 'Pivotal GemFire' with 'VMware GemFire'.
2020-07-26 22:30:20 -07:00
John Blum
3961cce1c8
Add test cases proving the OOTB, unsupported putAll(:Map<?, ?>) and putIfAbsent(key, value) Map methods of Region can be mocked by end-users.
2020-07-26 21:22:03 -07:00
John Blum
32c664db07
Remove uses of deprecated Mockito APIs.
2020-07-26 21:22:03 -07:00
John Blum
36795103e7
Rename @EnableGemFireGarbageCollector annotation to @EnableGemFireResourceCollector.
...
Rename all associated and appropriate uses of 'garbage' to 'resources'.
Resolves gh-21.
2020-06-17 20:07:28 -07:00
John Blum
af6340f8a0
Set the default 'destroyEventTypes' to AfterTestClassEvent.class.
2020-06-17 19:15:55 -07:00
John Blum
15077eb5f4
Rename @EnableGemFireMockObjects.destroyOnEvent annotation attribute to 'destroyOnEvents'.
...
Add additional test cases for the GemFireMockObjectsConfiguration class testing the ApplicationListener and BeanPostProcessor bean configurations.
2020-06-17 19:09:15 -07:00
John Blum
06aeaa62cf
Add Unit Tests for GemFireGarbageCollectorApplicationListener.
...
Resolves gh-21.
2020-06-17 17:18:58 -07:00
John Blum
ddfbfb3852
Add Unit Tests for GemFireGarbageCollectorConfiguration.
...
Resolves gh-21.
2020-06-17 17:18:49 -07:00
John Blum
96e9b05750
Add Spring TestExecutionListener implementation to destroy all GemFire/Geode Mock Objects when configured TestContextEvents by type are fired during the test execution lifecycle.
...
Resolves gh-20.
2020-05-21 21:47:02 -07:00
John Blum
4f4cfad6c2
Create enumeration of all Spring TestContext framework, TestContextEvent types.
...
Resolves gh-20.
2020-05-21 21:45:52 -07:00
John Blum
39f36ce9d0
Add Spring ApplicationListener implementation to destroy all GemFire/Geode Mock Objects when configured ApplicationEvents are fired in a Spring context.
...
Resolves gh-20.
2020-05-21 21:45:13 -07:00
John Blum
ff49f11a02
Add Unit Tests for GemFireMockObjectsBeanPostProcessor.
2020-05-21 21:43:21 -07:00
John Blum
fbb39b97b9
Add Unit Tests for GemFireMockObjectsApplicationContextInitializer.
2020-05-21 21:42:46 -07:00
John Blum
af9237eeb1
Add 'destroyOnEvent' configuration annotation attribute.
...
The 'destoryOnEvent' EnableGemFireMockObjects annotation attribute configures specific Spring ApplicationEvent types (Class) that will trigger the destruction of all GemFire/Geode Mock Objects.
Add bean definition and declaration for the DestroyGemFireMockObjectsApplicationListener.
Add Unit Tests for the GemFireMockObjectsConfiguration class.
Resolves gh-20.
2020-05-21 21:40:26 -07:00
John Blum
53893bd49f
Add support to suppress GemFire/Geode Mock Object destruction on ContextClosedEvents.
2020-05-19 21:59:22 -07:00
John Blum
6dec5b8d73
Add utility method to find and reserve allocated network ports.
2020-04-15 13:12:35 -07:00
John Blum
68c5edb974
Format source code.
...
Optimize imports.
2020-02-22 20:26:52 -08:00
John Blum
19847910c8
Optimize imports.
2020-02-22 20:17:34 -08:00
John Blum
01028ca116
Add Unit Tests for AEQ pause & resume event dispatching.
2019-11-04 12:25:41 -08:00