@Test
  public void testTxReferences() throws Exception {
    createCache(false);
    final CacheTransactionManager txMgr = cache.getCacheTransactionManager();
    txMgr.begin();
    try {
      final Object v = 7;
      region.put("key", v);
      assertTrue("expected get to return reference to v", region.get("key") == v);
      Region.Entry re = region.getEntry("key");
      assertTrue("expected Entry.getValue to return reference to v", re.getValue() == v);
      txMgr.rollback();
    } finally {
      try {
        txMgr.rollback();
      } catch (IllegalStateException ignore) {
      }
      closeCache();
    }
  }
Tests the functionality of the {@link CopyHelper#copy} method and the builtin copy-on-get Cache
functions.

@since GemFire 4.0
geode-core/src/integrationTest/java/org/apache/geode/CopyJUnitTest.java