private <K, V> List<CacheEvent<K, V>> assertForOpCount(String regionName, Operation operation,
      int count) {
    Region<K, V> region = getRootRegion().getSubregion(regionName);
    CertifiableTestCacheListener<K, V> ctl =
        (CertifiableTestCacheListener<K, V>) region.getAttributes()
            .getCacheListeners()[0];
    List<CacheEvent<K, V>> list = new ArrayList<>(ctl.getEventHistory());

    await().until(() -> {
      list.addAll(ctl.getEventHistory());
      return list.size() >= count;
    });
    int countOfOps = 0;
    for (CacheEvent<K, V> cacheEvent : list) {

      if (cacheEvent.getOperation() == operation) {
        countOfOps++;
      } else {
        logger.info("assertForOpCount: Got an unexpected message " + cacheEvent);
      }
    }

    assertThat(countOfOps).isEqualTo(count);
    assertThat(countOfOps)
        .describedAs("assertForOpCount: There were excess operations in the list " + list)
        .isEqualTo(list.size());
    return list;
  }
Tests the put operation of the {@link Pool}

@since GemFire 3.5
geode-core/src/distributedTest/java/org/apache/geode/cache/ConnectionPoolDUnitTest.java