@Override
      public void run() {
        try {
          final AttributesFactory factory = new AttributesFactory();
          factory.setPartitionAttributes(
              new PartitionAttributesFactory().setRedundantCopies(redundantCopies).create());
          factory.setEvictionAttributes(EvictionAttributes
              .createLRUEntryAttributes(maxEntriesForOtherVm, EvictionAction.LOCAL_DESTROY));

          final PartitionedRegion pr = (PartitionedRegion) createRootRegion(name, factory.create());
          assertNotNull(pr);
        } catch (final CacheException ex) {
          Assert.fail("While creating Partitioned region", ex);
        }
      }
This class tests total entry count of partitioned regions.
geode-core/src/distributedTest/java/org/apache/geode/internal/cache/PartitionedRegionEntryCountDUnitTest.java