Java 类com.google.common.collect.testing.testers.MapReplaceTester 实例源码

项目:JCTools    文件:NonBlockingHashMapTest.java   
private static <T> TestSuite mapTestSuite(TestMapGenerator<T, T> testMapGenerator, String name)
{
    return new MapTestSuiteBuilder<T, T>()
    {
        {
            usingGenerator(testMapGenerator);
        }

        @Override
        protected List<Class<? extends AbstractTester>> getTesters()
        {
            List<Class<? extends AbstractTester>> testers = new ArrayList<>(super.getTesters());
            // NonBlockingHashMap doesn't support null in putIfAbsent and provides putIfAbsentAllowsNull instead
            testers.remove(MapReplaceEntryTester.class);
            testers.remove(MapReplaceTester.class);
            return testers;
        }
    }.withFeatures(
        MapFeature.GENERAL_PURPOSE,
        CollectionSize.ANY,
        CollectionFeature.SUPPORTS_ITERATOR_REMOVE)
        .named(name)
        .createTestSuite();
}
项目:guava-mock    文件:MapTestSuiteBuilder.java   
@SuppressWarnings("unchecked") // Class parameters must be raw.
@Override
protected List<Class<? extends AbstractTester>> getTesters() {
  return Arrays.<Class<? extends AbstractTester>>asList(
      MapClearTester.class,
      MapComputeTester.class,
      MapComputeIfAbsentTester.class,
      MapComputeIfPresentTester.class,
      MapContainsKeyTester.class,
      MapContainsValueTester.class,
      MapCreationTester.class,
      MapEntrySetTester.class,
      MapEqualsTester.class,
      MapForEachTester.class,
      MapGetTester.class,
      MapGetOrDefaultTester.class,
      MapHashCodeTester.class,
      MapIsEmptyTester.class,
      MapMergeTester.class,
      MapPutTester.class,
      MapPutAllTester.class,
      MapPutIfAbsentTester.class,
      MapRemoveTester.class,
      MapRemoveEntryTester.class,
      MapReplaceTester.class,
      MapReplaceAllTester.class,
      MapReplaceEntryTester.class,
      MapSerializationTester.class,
      MapSizeTester.class,
      MapToStringTester.class);
}
项目:googles-monorepo-demo    文件:MapTestSuiteBuilder.java   
@SuppressWarnings("unchecked") // Class parameters must be raw.
@Override
protected List<Class<? extends AbstractTester>> getTesters() {
  return Arrays.<Class<? extends AbstractTester>>asList(
      MapClearTester.class,
      MapComputeTester.class,
      MapComputeIfAbsentTester.class,
      MapComputeIfPresentTester.class,
      MapContainsKeyTester.class,
      MapContainsValueTester.class,
      MapCreationTester.class,
      MapEntrySetTester.class,
      MapEqualsTester.class,
      MapForEachTester.class,
      MapGetTester.class,
      MapGetOrDefaultTester.class,
      MapHashCodeTester.class,
      MapIsEmptyTester.class,
      MapMergeTester.class,
      MapPutTester.class,
      MapPutAllTester.class,
      MapPutIfAbsentTester.class,
      MapRemoveTester.class,
      MapRemoveEntryTester.class,
      MapReplaceTester.class,
      MapReplaceAllTester.class,
      MapReplaceEntryTester.class,
      MapSerializationTester.class,
      MapSizeTester.class,
      MapToStringTester.class);
}
项目:guava    文件:MapTestSuiteBuilder.java   
@SuppressWarnings("unchecked") // Class parameters must be raw.
@Override
protected List<Class<? extends AbstractTester>> getTesters() {
  return Arrays.<Class<? extends AbstractTester>>asList(
      MapClearTester.class,
      MapComputeTester.class,
      MapComputeIfAbsentTester.class,
      MapComputeIfPresentTester.class,
      MapContainsKeyTester.class,
      MapContainsValueTester.class,
      MapCreationTester.class,
      MapEntrySetTester.class,
      MapEqualsTester.class,
      MapForEachTester.class,
      MapGetTester.class,
      MapGetOrDefaultTester.class,
      MapHashCodeTester.class,
      MapIsEmptyTester.class,
      MapMergeTester.class,
      MapPutTester.class,
      MapPutAllTester.class,
      MapPutIfAbsentTester.class,
      MapRemoveTester.class,
      MapRemoveEntryTester.class,
      MapReplaceTester.class,
      MapReplaceAllTester.class,
      MapReplaceEntryTester.class,
      MapSerializationTester.class,
      MapSizeTester.class,
      MapToStringTester.class);
}