You are viewing a plain text version of this content. The canonical link for it is here.
Posted to notifications@geode.apache.org by "demery-pivotal (GitHub)" <gi...@apache.org> on 2020/03/20 22:29:41 UTC

[GitHub] [geode] demery-pivotal commented on pull request #4820: GEODE-7826: start jmx-manager if the Geode Management Rest Service is enabled

Instead of adding a new test-only method, try this:
- Add a new `Supplier<InternalCache>` parameter to the `InternalLocator` constructor, and let the constructor store the supplier in a field for later use.
- Change `InternalLocator.getCache()` to call the supplier instead of calling `GemFireCacheImpl.getInstance()` directly.
- Change `InternalLocator.createLocator(…)` and `InternalLocatorIntegrationTest` to pass `GemFireCacheImpl::getInstance` to the `InternalLocator` constructor.
- In these new tests, pass the mock cache to the `InternalLocator` constructor.

[ Full content available at: https://github.com/apache/geode/pull/4820 ]
This message was relayed via gitbox.apache.org for notifications@geode.apache.org