geode-issues mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "ASF subversion and git services (JIRA)" <>
Subject [jira] [Commented] (GEODE-4487) Remove singleton calls from all tests in org.apache.geode.internal.offheap
Date Tue, 06 Feb 2018 06:51:00 GMT


ASF subversion and git services commented on GEODE-4487:

Commit c36a11356efac2ca942fac97f27e39d47a496ede in geode's branch refs/heads/feature/GEODE-3967
from [~dschneider]
[;h=c36a113 ]

GEODE-4487: Remove singleton calls from offheap package (#1382)

One test was using the singletons just to confirm the cache had been shutdown. It was easy
to change that test to not confirm the singleton was null but to instead ask if the test's
cache was closed.

The other test was testing DataType which is product code that is only used by tests to inspect
what is stored in offheap memory. The test was mocking the singleton methods because the product
DataType was using the singleton to decode a serialized PDX. I changed DataType to just do
less decoding of pdx. Now it will just say it was a pdx and give you the type number.

> Remove singleton calls from all tests in org.apache.geode.internal.offheap
> --------------------------------------------------------------------------
>                 Key: GEODE-4487
>                 URL:
>             Project: Geode
>          Issue Type: Sub-task
>          Components: offheap, tests
>            Reporter: Kirk Lund
>            Assignee: Darrel Schneider
>            Priority: Major
>              Labels: pull-request-available
>             Fix For: 1.5.0
>          Time Spent: 20m
>  Remaining Estimate: 0h
> These tests in org.apache.geode.internal.offheap invoke singleton getters.
> GemFireCacheImpl.getInstance():
> * OutOfOffHeapMemoryDUnitTest
> GemFireCacheImpl.getForPdx(String):
> * DataTypeJUnitTest
> InternalDistributedSystem.getAnyInstance():
> * OutOfOffHeapMemoryDUnitTest

This message was sent by Atlassian JIRA

View raw message